From 1eaf7210492e3cc968f26d848c6db7b4e603a657 Mon Sep 17 00:00:00 2001 From: bob Date: Tue, 23 Apr 2019 15:24:10 -0400 Subject: maybe working events? --- src/client/util/SelectionManager.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'src/client/util/SelectionManager.ts') diff --git a/src/client/util/SelectionManager.ts b/src/client/util/SelectionManager.ts index 92d78696e..0e7b374e9 100644 --- a/src/client/util/SelectionManager.ts +++ b/src/client/util/SelectionManager.ts @@ -1,9 +1,7 @@ -import { observable, action } from "mobx"; -import { DocumentView } from "../views/nodes/DocumentView"; +import { action, observable } from "mobx"; import { Document } from "../../fields/Document"; -import { Main } from "../views/Main"; import { MainOverlayTextBox } from "../views/MainOverlayTextBox"; -import { DragManager } from "./DragManager"; +import { DocumentView } from "../views/nodes/DocumentView"; export namespace SelectionManager { class Manager { -- cgit v1.2.3-70-g09d2 From 0e27df3127c91a7d48ef05c7075c7d26aca2bd7f Mon Sep 17 00:00:00 2001 From: Bob Zeleznik Date: Thu, 25 Apr 2019 01:38:42 -0400 Subject: fixed re-clicking inside text and resizing text with focus --- src/client/util/SelectionManager.ts | 2 +- src/client/views/DocumentDecorations.tsx | 1 + src/client/views/nodes/FormattedTextBox.scss | 3 ++- 3 files changed, 4 insertions(+), 2 deletions(-) (limited to 'src/client/util/SelectionManager.ts') diff --git a/src/client/util/SelectionManager.ts b/src/client/util/SelectionManager.ts index 0e7b374e9..da66bf3fc 100644 --- a/src/client/util/SelectionManager.ts +++ b/src/client/util/SelectionManager.ts @@ -63,7 +63,7 @@ export namespace SelectionManager { export function ReselectAll() { let sdocs = manager.ReselectAll(); - manager.ReselectAll2(sdocs); + setTimeout(() => manager.ReselectAll2(sdocs), 0); } export function SelectedDocuments(): Array { return manager.SelectedDocuments; diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx index 9995c1c3f..06d2f580c 100644 --- a/src/client/views/DocumentDecorations.tsx +++ b/src/client/views/DocumentDecorations.tsx @@ -437,6 +437,7 @@ export class DocumentDecorations extends React.Component<{}, { value: string }> e.stopPropagation(); this._resizing = ""; this.Interacting = false; + SelectionManager.ReselectAll(); if (e.button === 0) { e.preventDefault(); this._isPointerDown = false; diff --git a/src/client/views/nodes/FormattedTextBox.scss b/src/client/views/nodes/FormattedTextBox.scss index 59857bab3..5eb2bf7ce 100644 --- a/src/client/views/nodes/FormattedTextBox.scss +++ b/src/client/views/nodes/FormattedTextBox.scss @@ -22,10 +22,11 @@ overflow-x: hidden; color: initial; height: 100%; - pointer-events: none; + pointer-events: all; } .formattedTextBox-cont-hidden { overflow: hidden; + pointer-events: none; } .menuicon { -- cgit v1.2.3-70-g09d2