diff options
author | Andrew Dolgov <[email protected]> | 2018-11-23 14:21:54 +0300 |
---|---|---|
committer | Andrew Dolgov <[email protected]> | 2018-11-23 14:21:54 +0300 |
commit | 8fba996d54700b10e17931c74aab37f650ec976b (patch) | |
tree | 1287f6ea388a9cd4941b2214451956e2ccac7d67 | |
parent | 42bb935ae79b7d6ef614181cb00304539894ebfb (diff) |
use jquery keyup handler for outer window hotkeys
-rw-r--r-- | js/read.js | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -98,7 +98,7 @@ function prev_page() { function hotkey_handler(e) { try { - //console.log('K:' + e.which); + //console.log('K:' + e.which, e); if ($(".modal").is(":visible")) return; @@ -139,7 +139,9 @@ function resize_side_columns() { } $(document).ready(function() { - document.onkeydown = hotkey_handler; + $(document).on("keyup", function(e) { + hotkey_handler(e); + }); $("#left").on("mouseup", function(evt) { prev_page(); |