merge fix for embedded media repeated autoplay

This commit is contained in:
Hakim El Hattab 2013-06-09 16:44:03 +02:00
commit 033f3ab169
2 changed files with 10 additions and 7 deletions

File diff suppressed because one or more lines are too long

View File

@ -1231,7 +1231,8 @@ var Reveal = (function(){
} }
// Dispatch an event if the slide changed // Dispatch an event if the slide changed
if( indexh !== indexhBefore || indexv !== indexvBefore ) { var slideChanged = (indexh !== indexhBefore || indexv !== indexvBefore);
if( slideChanged ) {
dispatchEvent( 'slidechanged', { dispatchEvent( 'slidechanged', {
'indexh': indexh, 'indexh': indexh,
'indexv': indexv, 'indexv': indexv,
@ -1268,8 +1269,10 @@ var Reveal = (function(){
} }
// Handle embedded content // Handle embedded content
if (slideChanged) {
stopEmbeddedContent( previousSlide ); stopEmbeddedContent( previousSlide );
startEmbeddedContent( currentSlide ); startEmbeddedContent( currentSlide );
}
updateControls(); updateControls();
updateProgress(); updateProgress();