Refactored ~200 lines of code into task specific functions:
update_key_state()
open_log_file()
log_event()
post_log()
log_loop()
Motivation: Make the code more reusable for slightly different logging tasks. (My use case: log key frequency and n-gram statistics, respecting typing timing and pauses.)
Refactored ~200 lines of code into task specific functions:
update_key_state()
open_log_file()
log_event()
post_log()
log_loop()
Motivation: Make the code more reusable for slightly different logging tasks. (My use case: log key frequency and n-gram statistics, respecting typing timing and pauses.)