Skip to content

Commit

Permalink
first/last slide shortcut now uses shift modified, cmd conflicted wit…
Browse files Browse the repository at this point in the history
…h browser back/fwd
  • Loading branch information
hakimel committed May 27, 2019
1 parent 25e521a commit 99c3498
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions js/reveal.js
Original file line number Diff line number Diff line change
Expand Up @@ -1453,8 +1453,8 @@
keyboardShortcuts['↓ , J'] = 'Navigate down';
}

keyboardShortcuts['Home , ⌘/CTRL ←'] = 'First slide';
keyboardShortcuts['End , ⌘/CTRL →'] = 'Last slide';
keyboardShortcuts['Home , Shift ←'] = 'First slide';
keyboardShortcuts['End , Shift →'] = 'Last slide';
keyboardShortcuts['B , .'] = 'Pause';
keyboardShortcuts['F'] = 'Fullscreen';
keyboardShortcuts['ESC, O'] = 'Slide overview';
Expand Down Expand Up @@ -5192,8 +5192,8 @@

// Whitelist specific modified + keycode combinations
var prevSlideShortcut = event.shiftKey && event.keyCode === 32;
var firstSlideShortcut = ( event.metaKey || event.ctrlKey ) && keyCode === 37;
var lastSlideShortcut = ( event.metaKey || event.ctrlKey ) && keyCode === 39;
var firstSlideShortcut = event.shiftKey && keyCode === 37;
var lastSlideShortcut = event.shiftKey && keyCode === 39;

// Prevent all other events when a modifier is pressed
var unusedModifier = !prevSlideShortcut && !firstSlideShortcut && !lastSlideShortcut &&
Expand Down

0 comments on commit 99c3498

Please sign in to comment.