var ttd = this.ownerDocument,
evt = ttd.createEvent("TimeEvents");
this._starting = ttd.documentElement.getCurrentTime(); //getStartTimeメソッドで使う開始時刻
+ if (this.getCurrentTime() > 0) {
+ /*アニメーションの最中で、beginEventが起きるときは、endEventが前もって起こされる。SVG1.1の仕様を参照
+ *
+ * 19.4.2 Interface TimeEvent
+ * Note that if an element is restarted while it is currently playing, the element will raise an end event and another begin event, as the element restarts.
+ *
+ * http://www.w3.org/TR/SVG/animate.html#InterfaceTimeEvent
+ *
+ */
+ this.endElement();
+ this._currentFrame = 0;
+ }
evt.initTimeEvent("beginEvent", ttd.defaultView, 0);
this.dispatchEvent(evt);
/*新しくリストの頭を更新して、別の値も実行させるようにする*/
if (nci._start) {
var sti = nci._start[0];
if ((sti || (sti === 0)) && s1 <= sti && sti < s) {
- if (nci.getCurrentTime() > 0) {
- /*アニメーションの最中で、beginEventが起きるときは、endEventが前もって起こされる。SVG1.1の仕様を参照
- *
- * 19.4.2 Interface TimeEvent
- * Note that if an element is restarted while it is currently playing, the element will raise an end event and another begin event, as the element restarts.
- *
- * http://www.w3.org/TR/SVG/animate.html#InterfaceTimeEvent
- *
- */
- nci.endElement();
- nci._currentFrame = 0;
- }
nci.beginElement();
}
sti = void 0;