修复橡皮擦没有撤回功能

This commit is contained in:
X1627315083
2025-05-12 16:10:39 +08:00
parent 42dbe8ddc4
commit bcc12e3fa3
3 changed files with 6 additions and 2 deletions

View File

@@ -96,6 +96,9 @@ class myCanvas {
this.canvas.on("object:modified", ()=>{
this.updateCanvasState('')
});
this.canvas.on("mouse:up",()=>{
if(this.canvas.freeDrawingBrush.isEraser)this.updateCanvasState()
});
this.canvasKeyDown = this.canvasKeyDown.bind(this);
this.canvasKeyUp = this.canvasKeyUp.bind(this);