Implemented global hotkeys support.
Replaces InputController with InputThread that runs in an asynchronous thread and polls for key state updates. This allows us to get key updates even when the application is not in focus.