aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/PresBox.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/client/views/nodes/PresBox.tsx')
-rw-r--r--src/client/views/nodes/PresBox.tsx16
1 files changed, 5 insertions, 11 deletions
diff --git a/src/client/views/nodes/PresBox.tsx b/src/client/views/nodes/PresBox.tsx
index 755f6e166..521a3796b 100644
--- a/src/client/views/nodes/PresBox.tsx
+++ b/src/client/views/nodes/PresBox.tsx
@@ -718,19 +718,13 @@ export class PresBox extends ViewBoxBaseComponent<FieldViewProps, PresBoxSchema>
handled = true;
} if (e.keyCode === 8) { // delete (backspace) selected items
if (this.layoutDoc.presStatus === "edit") {
-
- let result: any = [];
runInAction(() => {
- for (let doc of this._selectedArray) {
- setTimeout(() => {
- const removed: boolean = this.removeDocument(doc);
- result.push(removed)
- console.log("Is removed? : " + " | " + removed);
- }, 100);
+ for (const doc of this._selectedArray) {
+ this.removeDocument(doc);
}
- this._selectedArray = []
- this._eleArray = []
- this._dragArray = []
+ this._selectedArray = [];
+ this._eleArray = [];
+ this._dragArray = [];
});
handled = true;
}