From e5bb1c8a5bdde5e55a20cbce72495b59ef727c68 Mon Sep 17 00:00:00 2001 From: dhrname Date: Sun, 9 Nov 2014 23:27:01 +0900 Subject: [PATCH] =?utf8?q?SMIL=E3=82=A2=E3=83=8B=E3=83=A1=E3=83=BC?= =?utf8?q?=E3=82=B7=E3=83=A7=E3=83=B3=E9=96=A2=E9=80=A3=E8=A6=81=E7=B4=A0?= =?utf8?q?=E3=81=AE=E3=82=A4=E3=83=B3=E3=82=BF=E3=83=BC=E3=83=95=E3=82=A7?= =?utf8?q?=E3=83=BC=E3=82=B9=E3=82=92base=E9=96=A2=E6=95=B0=E3=81=A7?= =?utf8?q?=E8=A1=A8=E7=8F=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- org/w3c/dom/svg.js | 45 +++++++++++++++++++++++---------------------- 1 file changed, 23 insertions(+), 22 deletions(-) diff --git a/org/w3c/dom/svg.js b/org/w3c/dom/svg.js index b9c53cb..20ba0ec 100644 --- a/org/w3c/dom/svg.js +++ b/org/w3c/dom/svg.js @@ -5065,7 +5065,8 @@ base("$event").SVGZoomEvents = base("$event").UIEvents.up("SVGZoomEvents").on("i /*readonly SVGPoint*/ this.newTranslate = base("$SVGPoint").up(); }); -function SVGAnimationElement() { +base.$1.up("http://www.w3.org/2000/svganimate") + .SVGAnimationElement = function() { /*SIEにおけるSVGElementでは、fill属性とStyleSheetを結びつける機構があるため、 *styleのsetPropertyメソッドを無効化させておく必要がある */ @@ -5242,7 +5243,7 @@ function SVGAnimationElement() { tar._values = [null, tar._to]; } else if (tar._by) { tar._values = [null, null, tar._by]; - } else if (!tar.hasChildNodes() && !tar.hasAttributeNS(null, "path")) { //SVGAnimateMotionElementに留意 + } else if (!tar.hasChildNodes() && !tar.hasAttributeNS(null, "path")) { //animateMotion要素に留意 /*アニメーションの効果が出ないように調整する *SMILアニメーションの仕様を参照 * @@ -5556,8 +5557,10 @@ NAIBU.Time = { }; NAIBU.Clip = []; -function SVGAnimateElement(){ - SVGAnimationElement.apply(this); + +base.$1["http://www.w3.org/2000/svganimate"] + .on("initialize", function (_doc) { + this.SVGAnimationElement(); /*NAIBU.Clipについては、NAIBU.Timeで使う *くわしくはNAIBU.Time.start関数のコードを参照 */ @@ -5740,8 +5743,7 @@ function SVGAnimateElement(){ this.addEventListener("repeatEvent", function(evt) { var tar = evt.target; }, false); -}; -SVGAnimateElement.prototype = Object._create(SVGAnimationElement); +} ); function SVGSetElement(){ SVGAnimationElement.apply(this); @@ -5815,8 +5817,10 @@ function SVGSetElement(){ }; SVGSetElement.prototype = Object._create(SVGAnimationElement); -function SVGAnimateMotionElement(){ - SVGAnimationElement.apply(this); +/*animateMotion要素はanimate要素を流用する*/ +base.$1["http://www.w3.org/2000/svganimateMotion"] = base.$1["http://www.w3.org/2000/svganimate"].up() + .on("initialize", function (_doc) { + this.SVGAnimationElement(); NAIBU.Clip[NAIBU.Clip.length] = this; this.addEventListener("DOMAttrModified", function(evt){ if (evt.eventPhase === /*Event.BUBBLING_PHASE*/ 3) { @@ -5948,8 +5952,7 @@ function SVGAnimateMotionElement(){ this.addEventListener("repeatEvent", function(evt) { var tar = evt.target; }, false); -}; -SVGAnimateMotionElement.prototype = Object._create(SVGAnimationElement); +} ) function SVGMPathElement() /* : SVGElement, @@ -5958,8 +5961,10 @@ function SVGMPathElement() /* : SVGURIReference.apply(this); }; -function SVGAnimateColorElement() { - SVGAnimationElement.apply(this); +/*animateColor要素はanimate要素を流用する*/ +base.$1["http://www.w3.org/2000/svganimateColor"] = base.$1["http://www.w3.org/2000/svganimate"].up() + .on("initialize", function (_doc) { + this.SVGAnimationElement(); NAIBU.Clip[NAIBU.Clip.length] = this; this._valueList = []; this.addEventListener("DOMNodeInserted", function(evt){ @@ -6056,11 +6061,12 @@ function SVGAnimateColorElement() { this.addEventListener("repeatEvent", function(evt) { var tar = evt.target; }, false); -}; -SVGAnimateColorElement.prototype = Object._create(SVGAnimationElement); +} ); -function SVGAnimateTransformElement() { - SVGAnimationElement.apply(this); +/*animateTransform要素はanimate要素を流用する*/ +base.$1["http://www.w3.org/2000/svganimateTransform"] = base.$1["http://www.w3.org/2000/svganimate"].up() + .on("initialize", function (_doc) { + this.SVGAnimationElement(); NAIBU.Clip[NAIBU.Clip.length] = this; this.addEventListener("beginEvent", function(evt) { var tar = evt.target, trans = tar.targetElement.transform; @@ -6086,8 +6092,7 @@ function SVGAnimateTransformElement() { this.addEventListener("repeatEvent", function(evt) { var tar = evt.target; }, false); -}; -SVGAnimateTransformElement.prototype = Object._create(SVGAnimationElement); +} ); base.$1.up("http://www.w3.org/2000/svgfont").on("initialize", function () /*: SVGElement, @@ -6266,10 +6271,6 @@ function SVGForeignObjectElement(_doc) /*: //#endif _SVG_IDL_ base("DOMImplementation")["http://www.w3.org/2000/svg"] = { - animateColor: SVGAnimateColorElement, - animate: SVGAnimateElement, - animateMotion: SVGAnimateMotionElement, - animateTransform:SVGAnimateTransformElement, clipPath: SVGClipPathElement, colorProfile: SVGColorProfileElement, cursor: SVGCursorElement, -- 2.11.0