kopia lustrzana https://github.com/backface/turtlestitch
record unsaved changes when relabelling a block
rodzic
a2645683f1
commit
c075cff8f0
|
@ -3363,7 +3363,12 @@ BlockMorph.prototype.relabel = function (alternativeSelectors) {
|
||||||
block.addShadow(new Point(3, 3));
|
block.addShadow(new Point(3, 3));
|
||||||
menu.addItem(
|
menu.addItem(
|
||||||
block.doWithAlpha(1, () => block.fullImage()),
|
block.doWithAlpha(1, () => block.fullImage()),
|
||||||
() => this.setSelector(selector, -offset)
|
() => {
|
||||||
|
this.setSelector(selector, -offset);
|
||||||
|
this.scriptTarget().parentThatIsA(
|
||||||
|
IDE_Morph
|
||||||
|
).recordUnsavedChanges();
|
||||||
|
}
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
menu.popup(this.world(), this.bottomLeft().subtract(new Point(
|
menu.popup(this.world(), this.bottomLeft().subtract(new Point(
|
||||||
|
|
|
@ -1352,6 +1352,9 @@ CustomCommandBlockMorph.prototype.relabel = function (alternatives) {
|
||||||
() => {
|
() => {
|
||||||
this.definition = def;
|
this.definition = def;
|
||||||
this.refresh();
|
this.refresh();
|
||||||
|
this.scriptTarget().parentThatIsA(
|
||||||
|
IDE_Morph
|
||||||
|
).recordUnsavedChanges();
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
Ładowanie…
Reference in New Issue