diff options
author | Marius Mathiesen <marius@shortcut.no> | 2009-10-13 14:27:14 +0200 |
---|---|---|
committer | Johan Sørensen <johan@johansorensen.com> | 2009-11-04 15:23:25 +0100 |
commit | fc936e21936fb825d04380af2ba49d67d708e278 (patch) | |
tree | 541a12d66abed6d0eb9a42788279b8104802004c | |
parent | 6ce2d1d702e90a99fcf53826f2b825396906b204 (diff) | |
download | gitorious-mainline-outdated-fc936e21936fb825d04380af2ba49d67d708e278.zip gitorious-mainline-outdated-fc936e21936fb825d04380af2ba49d67d708e278.tar.gz gitorious-mainline-outdated-fc936e21936fb825d04380af2ba49d67d708e278.tar.bz2 |
Using a keydown listener to correctly intercept Esc presses
-rw-r--r-- | public/javascripts/application.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/public/javascripts/application.js b/public/javascripts/application.js index 0d39592..2916aaf 100644 --- a/public/javascripts/application.js +++ b/public/javascripts/application.js @@ -952,8 +952,8 @@ Gitorious.CommentForm = function(path){ return false; }); - commentContainer.keypress(function(e){ - if (e.which == 0) { + commentContainer.keydown(function(e){ + if (e.which == 27) { // Escape Gitorious.CommentForm.destroyAll(); } }) |