Input manager. work in progress