OSDN Git Service

Support the init method of the object
authordhrname <dhrname@users.sourceforge.jp>
Sat, 16 May 2015 14:01:12 +0000 (23:01 +0900)
committerdhrname <dhrname@users.sourceforge.jp>
Sat, 16 May 2015 14:01:12 +0000 (23:01 +0900)
org/w3c/dom/smil.js

index 2dc7ec9..99f3e38 100644 (file)
@@ -835,17 +835,20 @@ base("$calcMode").up("$attribute").mix( {
   defaultValue: "",\r
 \r
   init: function(ele) {\r
-    this.push(ele);\r
+    var line = this.push(ele);\r
     if (ele && ele.getAttributeNS) {\r
       this.to = ele.getAttributeNS(null, "to") || "";\r
       this.attrName = ele.getAttributeNS(null, "attributeName") || "";\r
     }\r
     var thisele = this.element;\r
-    if (thisele) {\r
+    if (line && thisele) {\r
       this.defaultValue = thisele.getAttributeNS(null, this.attrName)\r
          || thisele.ownerDocument.defaultView.getComputedStyle(thisele, "").getPropertyValue(this.attrName);\r
+      line.setFrame = function () {\r
+        this.element.setAttributeNS(null, this.attrName, this.to);\r
+      }.bind(this);\r
     }\r
-    thisele = void 0;\r
+    line = thisele = void 0;\r
   }\r
 });\r
 \r