Merge pull request #1100 from adroitwhiz/delete-origpos

Delete item.data.origPos instead of setting it to null
This commit is contained in:
adroitwhiz 2020-06-03 11:37:51 -04:00 committed by GitHub
commit d02fe5fcf0
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -206,10 +206,10 @@ class MoveTool {
let moved = false;
// resetting the items origin point for the next usage
for (const item of this.selectedItems) {
if (item.data && item.data.origPos && !item.position.equals(item.data.origPos)) {
moved = true;
if (item.data.origPos) {
if (!item.position.equals(item.data.origPos)) moved = true;
delete item.data.origPos;
}
item.data.origPos = null;
}
this.selectedItems = null;
this.selectionCenter = null;