Skip to content

Commit

Permalink
2.0.8 hotfix
Browse files Browse the repository at this point in the history
  • Loading branch information
pissang committed Mar 12, 2015
1 parent d0301a7 commit f35829e
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
14 changes: 11 additions & 3 deletions build/zrender-original.js
Original file line number Diff line number Diff line change
Expand Up @@ -9036,7 +9036,9 @@ define('zrender/Group',['require','./tool/guid','./tool/util','./mixin/Transform
Group.prototype.removeChild = function(child) {
var idx = util.indexOf(this._children, child);

this._children.splice(idx, 1);
if (idx >= 0) {
this._children.splice(idx, 1);
}
child.parent = null;

if (this._storage) {
Expand Down Expand Up @@ -11041,7 +11043,10 @@ define(

var animator = this.animation.animate(target, { loop: loop })
.done(function () {
animators.splice(el.__animators.indexOf(animator), 1);
var idx = util.indexOf(el.__animators, animator);
if (idx >= 0) {
animators.splice(idx, 1);
}
if (animators.length === 0) {
// 从animatingElements里移除
var idx = util.indexOf(animatingElements, el);
Expand Down Expand Up @@ -11070,7 +11075,10 @@ define(
}
if (len > 0) {
var animatingElements = this.animatingElements;
animatingElements.splice(animatingElements.indexOf(el), 1);
var idx = util.indexOf(animatingElements, el);
if (idx >= 0) {
animatingElements.splice(idx, 1);
}
}

animators.length = 0;
Expand Down
2 changes: 1 addition & 1 deletion build/zrender.js

Large diffs are not rendered by default.

0 comments on commit f35829e

Please sign in to comment.