From e6932e78e54457391a07e70bc85fc1f4f792e22f Mon Sep 17 00:00:00 2001 From: Geireann Lindfield Roberts <60007097+geireann@users.noreply.github.com> Date: Thu, 22 Oct 2020 22:46:03 +0800 Subject: presBox restoring undoBatch for remove docs --- src/client/views/nodes/PresBox.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/client/views/nodes/PresBox.tsx b/src/client/views/nodes/PresBox.tsx index 39e1ec58b..80cf848e5 100644 --- a/src/client/views/nodes/PresBox.tsx +++ b/src/client/views/nodes/PresBox.tsx @@ -690,14 +690,14 @@ export class PresBox extends ViewBoxBaseComponent switch (e.key) { case "Backspace": if (this.layoutDoc.presStatus === "edit") { - runInAction(() => { + undoBatch(action(() => { for (const doc of this._selectedArray) { this.removeDocument(doc); } this._selectedArray = []; this._eleArray = []; this._dragArray = []; - }); + }))(); handled = true; } break; @@ -1827,7 +1827,7 @@ export class PresBox extends ViewBoxBaseComponent
-
{presKeyEvents ? "Key events are active" : "Keys are not active - click anywhere on the presentation trail to activate keys"}
}> +
{presKeyEvents ? "Key are active" : "Keys are not active - click anywhere on the presentation trail to activate keys"}
}>
-- cgit v1.2.3-70-g09d2