diff --git a/lib/timeline/component/item/Item.js b/lib/timeline/component/item/Item.js index 9dd4e055e..551ffc356 100644 --- a/lib/timeline/component/item/Item.js +++ b/lib/timeline/component/item/Item.js @@ -64,7 +64,10 @@ Item.prototype.setData = function(data) { if (groupChanged && this.parent != null) { this.parent.itemSet._moveToGroup(this, data.group); } - this.parent.stackDirty = true; + + if (this.parent) { + this.parent.stackDirty = true; + } var subGroupChanged = data.subgroup != undefined && this.data.subgroup != data.subgroup; if (subGroupChanged && this.parent != null) {