mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 16:56:36 -04:00
Fix IO masks not saving when scaled (#4021)
* trigger save after modifying object * remove redundant save already called by undoStack.onObjectModified or setShapePosition
This commit is contained in:
parent
e989564be2
commit
d39284e101
2 changed files with 2 additions and 2 deletions
|
@ -116,7 +116,6 @@ function initCanvas(): fabric.Canvas {
|
|||
modifiedPolygon(canvas, evt.target);
|
||||
undoStack.onObjectModified();
|
||||
}
|
||||
saveNeededStore.set(true);
|
||||
});
|
||||
canvas.on("text:editing:entered", function() {
|
||||
textEditingState.set(true);
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
import { fabric } from "fabric";
|
||||
import { get } from "svelte/store";
|
||||
|
||||
import { opacityStateStore } from "../store";
|
||||
import { opacityStateStore, saveNeededStore } from "../store";
|
||||
import type { Size } from "../types";
|
||||
|
||||
export const SHAPE_MASK_COLOR = "#ffeba2";
|
||||
|
@ -244,6 +244,7 @@ const setShapePosition = (
|
|||
}
|
||||
|
||||
object.setCoords();
|
||||
saveNeededStore.set(true);
|
||||
};
|
||||
|
||||
export function enableUniformScaling(canvas: fabric.Canvas, obj: fabric.Object): void {
|
||||
|
|
Loading…
Reference in a new issue