move libs into the lib folder and refactor InputManager to be an event-base singleton