Commit ae328760 authored by Oleg Roschupkin's avatar Oleg Roschupkin

Fix issue with inner navigation.

It was working in list mode.
parent 992b467b
...@@ -223,7 +223,8 @@ ...@@ -223,7 +223,8 @@
// Shortcut for alt, shift and meta keys // Shortcut for alt, shift and meta keys
if (e.altKey || e.ctrlKey || e.metaKey) { return; } if (e.altKey || e.ctrlKey || e.metaKey) { return; }
var currentSlideNumber = getCurrentSlideNumber(); var currentSlideNumber = getCurrentSlideNumber(),
innerNavigationCompleted = true;
switch (e.which) { switch (e.which) {
case 116: // F5 case 116: // F5
...@@ -268,16 +269,23 @@ ...@@ -268,16 +269,23 @@
case 74: // j case 74: // j
e.preventDefault(); e.preventDefault();
// Only go to next slide if current slide have no inner if (!isListMode() ) {
// navigation or inner navigation is fully shown // Inner navigation is "completed" if current slide have
// NOTE: But first of all check if there is no current slide // no inner navigation or inner navigation is fully shown
innerNavigationCompleted = !slideList[currentSlideNumber].hasInnerNavigation ||
-1 === increaseInnerNavigation(currentSlideNumber);
} else {
// Also inner navigation is always "completed" if we are in
// list mode
innerNavigationCompleted = true;
}
// NOTE: First of all check if there is no current slide
if ( if (
-1 === currentSlideNumber || -1 === currentSlideNumber || innerNavigationCompleted
!slideList[currentSlideNumber].hasInnerNavigation ||
-1 === increaseInnerNavigation(currentSlideNumber)
) { ) {
currentSlideNumber++; currentSlideNumber++;
goToSlide(currentSlideNumber); goToSlide(currentSlideNumber);
// We must run slideshow only in full mode
if (!isListMode()) { if (!isListMode()) {
runSlideshowIfPresented(currentSlideNumber); runSlideshowIfPresented(currentSlideNumber);
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment