this._resized = true;
var director = this;
this._rafId = window.requestAnimationFrame(function _ (t) {
- if (!director._timerStart) {
+ if (!director._timerStart)
director._timerStart = t;
- director._audioOffset = yuu.audio
- ? yuu.audio.currentTime * 1000 - t
- : 0;
- }
director._rafId = window.requestAnimationFrame(_);
director.render(t);
});
yuu.downloadURL(
yuu.canvas.toDataURL("image/png"),
document.title + " (" + date + ").png");
- this.toast("\uf030", 0.5, "screenshot");
+ this.toast("📷", 0.5, "screenshot");
} catch (exc) {
var dialog = yuu.showError(exc);
if (dialog)
/** Tick and render all scenes, bottom to top */
var i;
+ this._audioOffset = yuu.audio
+ ? yuu.audio.currentTime * 1000 - t
+ : 0;
+
if (this._resized) {
this._dispatchSceneInput("resize", [yuu.canvas]);
this._resized = false;
}
}, elements);
- yf.each(function (a) {
- a.onclick = function (event) {
- yuu.openURL(this.href);
- yuu.stopPropagation(event, true);
- };
- }, element.querySelectorAll("a[href]:not([yuu-href-internal])"));
-
this._director = director;
element.className = className + " " + this.animation;
yuu.defaultKeybinds.bind("f11", "++fullscreen");
yuu.defaultKeybinds.bind("f12", "screenshot");
yuu.defaultKeybinds.bind(
- "control+s", "++mute && toast \uf026 1 mute || toast \uf028 1 mute");
+ "control+s", "++mute && toast 🔈 1 mute || toast 🔊 1 mute");
var director = yuu.director = new yuu.Director();
/** The standard director */
yuu.registerInitHook(function () {
- return yuu.ready(director.scenes);
+ return yuu.ready(director._scenes);
});
});