Permalink
Browse files

Tabbed interface: Now ignoring keystrokes modifed by the control, alt…

… and meta keys
  • Loading branch information...
pjackson28 committed Mar 18, 2014
1 parent 11ad5d8 commit 5446bc2188f0c293ef60aed9ef3d9c50e2720a1b
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/js/workers/tabbedinterface.js
@@ -184,7 +184,7 @@
isKeySelect = e.keyCode === 13 || e.keyCode === 32; // enter, space
isKeyPrev = e.keyCode === 37 || e.keyCode === 38; // left, up
isKeyNext = e.keyCode === 39 || e.keyCode === 40; // right, down
if (isKeySelect || isKeyPrev || isKeyNext) {
if ((isKeySelect || isKeyPrev || isKeyNext) && !(e.ctrlKey || e.altKey || e.metaKey)) {
if (opts.cycle) {
stopCycle();
}
@@ -315,7 +315,7 @@
$toggleButton = $toggleRow.find('a');
$nav.append($toggleRow);
$toggleRow.click(toggleCycle).on('keydown', function (e) {
if (e.keyCode === 32) {
if (e.keyCode === 32 && !(e.ctrlKey || e.altKey || e.metaKey)) {
toggleCycle();
return e.preventDefault();
}

0 comments on commit 5446bc2

Please sign in to comment.