robustify bind:currentTime - fixes #3524

pull/3530/head
Richard Harris 5 years ago
parent 41f5961ef9
commit 63ae77112c

@ -472,8 +472,10 @@ export default class ElementWrapper extends Wrapper {
function ${handler}() {
${animation_frame && deindent`
@_cancelAnimationFrame(${animation_frame});
if (!${this.var}.paused) ${animation_frame} = @raf(${handler});`}
${needs_lock && `${lock} = true;`}
if (!${this.var}.paused) {
${animation_frame} = @raf(${handler});`}
${needs_lock && `${lock} = true;`}
}
ctx.${handler}.call(${this.var}${contextual_dependencies.size > 0 ? ', ctx' : ''});
}
`);

Loading…
Cancel
Save