fix cancel action for select tool
Signed-off-by: Victor Seiji Hariki <victorseijih@gmail.com> Former-commit-id: 0bfa9a2cae4aa080571ae8eca576c94c023b6d44
This commit is contained in:
parent
97f3a54644
commit
8419f52f43
1 changed files with 7 additions and 0 deletions
|
@ -62,6 +62,13 @@ const selectTransformTool = () =>
|
|||
};
|
||||
|
||||
state.reset = () => {
|
||||
if (state.selected)
|
||||
imgCtx.drawImage(
|
||||
state.selected.image,
|
||||
state.selected.original.x,
|
||||
state.selected.original.y
|
||||
);
|
||||
|
||||
if (state.dragging) state.dragging = null;
|
||||
else state.selected = null;
|
||||
|
||||
|
|
Loading…
Reference in a new issue