Recompile

This commit is contained in:
Tim Mickel 2016-05-02 22:34:16 -04:00
parent 6bbeb2d0fe
commit 6906a8dc27
2 changed files with 21 additions and 19 deletions

32
vm.js
View file

@ -1308,8 +1308,23 @@
Runtime.prototype.moveBlock = function (e) {
var _this = this;
// Block has a new parent
if (e.oldParent === undefined && e.newParent !== undefined) {
// Block was removed from parent
if (e.newParent === undefined && e.oldParent !== undefined) {
// Add stack
_this.stacks.push(e.id);
// Update old parent
if (e.oldField === undefined) {
_this.blocks[e.oldParent].next = null;
} else {
delete _this.blocks[e.oldParent].fields[e.oldField];
}
} else if (e.newParent !== undefined) {
// Block was moved to a new parent
// Either happens because it was previously parentless
// (e.oldParent === undefined)
// or because a block was moved in front of it.
// Remove stack
_this._deleteStack(e.id);
@ -1324,19 +1339,6 @@
};
}
}
// Block was removed from parent
if (e.newParent === undefined && e.oldParent !== undefined) {
// Add stack
_this.stacks.push(e.id);
// Update old parent
if (e.oldField === undefined) {
_this.blocks[e.oldParent].next = null;
} else {
delete _this.blocks[e.oldParent].fields[e.oldField];
}
}
};
/**

8
vm.min.js vendored

File diff suppressed because one or more lines are too long