Add saveState calls after layer modifications

Added calls to saveState() after scaling, rotating, and removing layers to ensure changes are properly recorded in the undo/redo history. Also refactored the matting button UI for better layout and ensured saveState is called after matting results are applied.
This commit is contained in:
Dariusz L
2025-06-24 17:30:32 +02:00
parent 3922572315
commit 64550609b8
2 changed files with 76 additions and 63 deletions

View File

@@ -1111,6 +1111,7 @@ export class Canvas {
layer.height *= scale;
});
this.render();
this.saveState();
}
rotateLayer(angle) {
@@ -1118,6 +1119,7 @@ export class Canvas {
layer.rotation += angle;
});
this.render();
this.saveState();
}
updateCanvasSize(width, height, saveHistory = true) {