Correct keyboard events