From acf683f271112642a5de9a83687f649fd8d51748 Mon Sep 17 00:00:00 2001 From: dhrname Date: Mon, 7 Nov 2016 22:06:58 +0900 Subject: [PATCH] Modify the updateList method for the zero-start problem --- org/w3c/dom/smil.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/org/w3c/dom/smil.js b/org/w3c/dom/smil.js index c7636e4..fc25d5e 100644 --- a/org/w3c/dom/smil.js +++ b/org/w3c/dom/smil.js @@ -198,15 +198,15 @@ base("$frame").mix ( { var startTime = this.getMaxList(f, this.beginList), endTime = this.getMaxList(f, this.endList), cacheBegin = this.begin; - if ( (state === wait) || (state === post) ) { + if ( (!startTime) && (state === wait) ) { + /*開始時刻が0ならば、アニメーションを開始*/ + this.begin = 0; + this.state = begin; + } else if ( (state === wait) || (state === post) ) { if (startTime > cacheBegin) { this.state = begin; /*beginプロパティに開始時刻をキャッシュ用に保存*/ this.begin = startTime; - } else if (!startTime) { - /*開始時刻が0ならば、アニメーションを開始*/ - this.begin = 0; - this.state = begin; } } else if (state === begin) { if (endTime >= cacheBegin) { -- 2.11.0