]> git.sesse.net Git - remoteglot/commitdiff
Add some keyboard shortcuts.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 5 Sep 2014 05:11:38 +0000 (07:11 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 5 Sep 2014 05:11:38 +0000 (07:11 +0200)
www/js/remoteglot.js

index 565b61dd686ce2b57668183aff70e30b8760e366..47bd62fe160ed1f38472cae89e06002417ac6a50 100644 (file)
@@ -711,6 +711,13 @@ var init = function() {
                update_highlight();
                redraw_arrows();
        });
+       $(window).keyup(function(event) {
+               if (event.which == 39) {
+                       next_move();
+               } else if (event.which == 37) {
+                       prev_move();
+               }
+       });
 };
 $(document).ready(init);