catch button keyboard input