Add a sleep on start, add a scan function and tweak decide -> shift. #7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The sleep is to give X a chance to get the enter release event which
will solve some issues (enter repeat and possibly disabling a laptop
trackpad at least). Kinda of a hack but not sure how else to solve
this, since the press and release come from different keyboards X does
not seem to connect them.
Add a --scan option which will test all the files in /dev/input to try
to find keyboards and print info about any found.
Made some changes to the decide -> shift state change. It was possible
to have a press sent without a release (not a common case but I hit it a
couple of times) and this will cause some laptop trackpads to be
disabled (X seems to be disabling the trackpad because it thinks a key is being
pressed).