prioritize closing preview when ESC is pressed

This commit is contained in:
Hakim El Hattab 2013-10-13 11:47:04 -04:00
parent 88d84e4551
commit e14f5a95da
2 changed files with 8 additions and 3 deletions

View file

@ -2458,7 +2458,12 @@ var Reveal = (function(){
}
// ESC or O key
else if ( ( event.keyCode === 27 || event.keyCode === 79 ) && supports3DTransforms ) {
if( dom.preview ) {
closePreview();
}
else {
toggleOverview();
}
event.preventDefault();
}

4
js/reveal.min.js vendored

File diff suppressed because one or more lines are too long