keyboard events fix