update InputManager and KeyListener classes