Fix enlarging for paste
Fix warning dialog "History node switched during undoable callback for Paste: Enlarge. This shouldn't happen." Don't do an undoable inside an undoable.main
parent
e48d5ed955
commit
2f1c431f3f
|
@ -820,9 +820,10 @@ function paste(img){
|
||||||
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
ctx.fillRect(0, 0, canvas.width, canvas.height);
|
||||||
}
|
}
|
||||||
ctx.putImageData(original, 0, 0);
|
ctx.putImageData(original, 0, 0);
|
||||||
do_the_paste();
|
|
||||||
$canvas_area.trigger("resize");
|
|
||||||
});
|
});
|
||||||
|
// (undoable callback is synchronous, so this runs after it)
|
||||||
|
do_the_paste();
|
||||||
|
$canvas_area.trigger("resize");
|
||||||
})[0].focus();
|
})[0].focus();
|
||||||
$w.$Button("Crop", () => {
|
$w.$Button("Crop", () => {
|
||||||
$w.close();
|
$w.close();
|
||||||
|
|
Loading…
Reference in New Issue