Skip to content

Commit

Permalink
don't call onStepLeave if reselecting same step
Browse files Browse the repository at this point in the history
  • Loading branch information
bartaz committed Mar 19, 2012
1 parent d8d707c commit 0508feb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions impress.js/js/impress.js
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@

expectedTransitionTarget = target.scale > currentState.scale ? root : canvas;

if (activeStep) {
if (activeStep && activeStep !== el) {
onStepLeave(activeStep);
}

Expand Down Expand Up @@ -647,7 +647,6 @@

// rescale presentation when window is resized
window.addEventListener("resize", throttle(function () {
log("resize", document.querySelector(".active").id )
// force going to active step again, to trigger rescaling
api.goto( document.querySelector(".active"), 500 );
}, 250), false);
Expand Down

0 comments on commit 0508feb

Please sign in to comment.