Create object to handle key events