Keyboard handling corrections