OSDN Git Service

Lighten the _setEndFrame method of the
authordhrname <dhrname@users.sourceforge.jp>
Wed, 9 Nov 2016 13:16:33 +0000 (22:16 +0900)
committerdhrname <dhrname@users.sourceforge.jp>
Wed, 9 Nov 2016 13:16:33 +0000 (22:16 +0900)
org/w3c/dom/smil.js

index e3d92c7..d84a362 100644 (file)
@@ -1868,24 +1868,26 @@ base("$calcMode").up("$attribute").mix( {
      if (!list) {\r
        return;\r
      }\r
+     var item = list[this.numberOfList];\r
      if (this.fill === "remove") {\r
-       if (!list[this.numberOfList]) {\r
+       if (!item) {\r
          return;\r
        } else if (!this.isSum) {\r
          /*凍結処理をしないで、かつ、元の状態に戻して、効果が出ないようにする*/\r
-         list[this.numberOfList].isPlaying = false;\r
+         item.isPlaying = false;\r
        } else {\r
          /*凍結処理をしないで、かつ、効果を出すが、変形させないようにする*/\r
-         list[this.numberOfList].value = "translate(0)";\r
+         item.value = "translate(0)";\r
        }\r
      } else {\r
        /*凍結処理をする\r
         * 自前のtocallメソッドはvalueプロパティを書きかえてしまうため、\r
         * 上書きメソッドを呼び出す*/\r
-       list[this.numberOfList].value = this.type+ "(" \r
+       item.value = this.type+ "(" \r
                                       +this.$animateElement.tocall.call( this, this.getAdvanceEnd($list) )+ ")";\r
      }\r
      this.setAttribute( this.joinList(this.defaultValue || "") );\r
+     item = void 0;\r
    },\r
    \r
     /*setAddメソッドのオーバライド\r