Updated user input handling.