Fixed keyboard control functionality.