Change from keyup to keydown