Switch to keydown event to support arrow keys in chrome