Andreas Schulz wrote: >> Why aren't you using a callback in learn_from_remote() (which would, I >> assume pass through to LearnIR)? > > I atually considered a callback for a short while initially, but then > decided against it, since it would not give much useful information. > The most important progress for learning is the timeout for reception > of the signal (4 sec), and that is completely handled by the low-level > driver, so no way for a callback to indicate that the time is running > out - thus I made up my own 4sec gauge in the Python GUI as a separate > task. The actual reception of a IR signal then is so fast that it's over > before you've could have noticed that there was a progress bar filling up. > >> You sorta fake it up in concordance.c, but LearnIR() has a lot of knowledge >> of progress, it seems and a better progress meter could be given to the >> user. > > ?? All concordance gives is a crude ASCII-rendering of the received signal - > after all of it is received.
in _learn_ir_commands(), you call: cb_print_percent_status(1, 1, 1, NULL); Which is just going to print a 100% immediately. In LearnIR(), however, there's tons of stages - readreport, handle the response, validation, writereport, encode... these stages could be equal precentages, or the long ones can be given a part of the whole percentage, or whatever. I won't block the patch on this - I'm just curious if this wouldn't be better. > It's working fine this way with my LINUX as well (at least the parts of the > code that I tested), but I can't speak for older versions. Cool. > On my list for this week - hopefully I got the indentation settings of > kdevelop right now.. Is there something like Java 'checkstyle' for C/C++? Not that I know of. > No idea why this should confuse anyone. IMHO it's worth to be mentioned > that you can navigate through the list BOTH forward and back (which AFAIR > you can't in Logitech's web interface). I'm fine listing some of the features - it was the "now" thing I was trying to avoid. Don't sweat it, when I apply the patch, I'll reconsider and adapt as I see fit. > So would (IMHO) setting shiftwidth=3, tabstop=3, expandtab and > textwidth=100.. I will *never* have code with textwidth > 80. I don't like the tabs, I plan to move it to 2 or 4 spaces at some point. > Seriously, I would rather keep prompt, key choices and defaut choice strings > in place. I don't see any such string variables anwhere else in the code > anyway... You don't think string prompt_without_upload = "[R]etry same key, [N]ext key, [Q]uit" string prompt_with_upload = ... ... if (!(*options).noweb) { user_cmd = get_cmd(prompt_with_upload, keys_with_upload, 'U'); } else { user_cmd = get_cmd(prompt_without_upload, keys_without_upload, 'N'); } Looks much cleaner? You can base prompt_with_upload on prompt_without_upload and only have to update one place if you add a new option. It's up to you, I won't hold the patch because of it. Though, while I'm at it, your calls to cb_print_percent_status() and post_new_code() are both over 80 chars and don't need to be. Also, please change: delete_encoded_signal(post_string); /* done, free memory */ to: /* done, free memory */ delete_encoded_signal(post_string); I think I put that in the docs. If not, sorry. > Just a few more days, and an updated patch should be ready. Cool! Looking forward to the new ones. Sorry I took so long to respond. -- Phil Dibowitz [EMAIL PROTECTED] Open Source software and tech docs Insanity Palace of Metallica http://www.phildev.net/ http://www.ipom.com/ "Never write it in C if you can do it in 'awk'; Never do it in 'awk' if 'sed' can handle it; Never use 'sed' when 'tr' can do the job; Never invoke 'tr' when 'cat' is sufficient; Avoid using 'cat' whenever possible" -- Taylor's Laws of Programming
signature.asc
Description: OpenPGP digital signature
------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________ concordance-devel mailing list concordance-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/concordance-devel