Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better input handling #46

Open
OptimusPi opened this issue Jan 24, 2019 · 0 comments
Open

Better input handling #46

OptimusPi opened this issue Jan 24, 2019 · 0 comments
Assignees

Comments

@OptimusPi
Copy link
Owner

Instead of calling the input handler from different areas of the code, make a thread that always checks. Not sure how fast to check, but could get by with between 100 to <=1000 times per second.

There should be at least 1 millisecond sleep. Checking returns nearly instantly if there was no input. Change if statement to while loop so it runs "faster" if there is more input to process.

This is important for blocking functions such as reconnect with 10 second timeout: that's 10 seconds of input blocking that prevents the user from closing the client. That is not acceptable.

Make input handle checking its own thread and be done with it. :)

@OptimusPi OptimusPi self-assigned this Jan 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant