keyboard
keyboard copied to clipboard
Fix issue #397: Event listener fails when keyboard is disconnected
Issue #397
I encountered the issue in a *nix machine (Ubuntu 16.04). The fix makes it so that we don't read the input file when a keyboard is disconnected by checking the 'readable()' method on the file pointer, in Ubuntu when the keyboard is re-connected the 'readable()' method returns True and everything works as usual.