Add support for key events