1
0
Fork 0

enable pos-startup config of autoSlide

This commit is contained in:
Hakim El Hattab 2013-03-04 15:59:44 -05:00
parent 7081f901da
commit 7db0d9c17d
2 changed files with 10 additions and 8 deletions

View File

@ -77,9 +77,8 @@ var Reveal = (function(){
dependencies: [] dependencies: []
}, },
// Stores if the next slide should be shown automatically // The current auto-slide duration
// after n milliseconds autoSlide = 0,
autoSlide = config.autoSlide,
// The horizontal and vertical index of the currently active slide // The horizontal and vertical index of the currently active slide
indexh = 0, indexh = 0,
@ -316,9 +315,6 @@ var Reveal = (function(){
// Read the initial hash // Read the initial hash
readURL(); readURL();
// Start auto-sliding if it's enabled
cueAutoSlide();
// Notify listeners that the presentation is ready but use a 1ms // Notify listeners that the presentation is ready but use a 1ms
// timeout to ensure it's not fired synchronously after #initialize() // timeout to ensure it's not fired synchronously after #initialize()
setTimeout( function() { setTimeout( function() {
@ -401,6 +397,12 @@ var Reveal = (function(){
// Force a layout to make sure the current config is accounted for // Force a layout to make sure the current config is accounted for
layout(); layout();
// Reflect the current autoSlide value
autoSlide = config.autoSlide;
// Start auto-sliding if it's enabled
cueAutoSlide();
} }
/** /**

4
js/reveal.min.js vendored

File diff suppressed because one or more lines are too long