From d8bbce0a71951472449c6e87720fb0a21a341b83 Mon Sep 17 00:00:00 2001 From: bobzel Date: Mon, 22 Apr 2019 11:46:02 -0400 Subject: from last --- src/client/views/DocumentDecorations.tsx | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/client/views/DocumentDecorations.tsx b/src/client/views/DocumentDecorations.tsx index 3eefe0b68..7d9166c86 100644 --- a/src/client/views/DocumentDecorations.tsx +++ b/src/client/views/DocumentDecorations.tsx @@ -25,7 +25,6 @@ export const Flyout = higflyout.default; @observer export class DocumentDecorations extends React.Component<{}, { value: string }> { static Instance: DocumentDecorations; - @observable _resizer = ""; private _isPointerDown = false; private keyinput: React.RefObject; private _documents: DocumentView[] = SelectionManager.SelectedDocuments(); @@ -46,6 +45,8 @@ export class DocumentDecorations extends React.Component<{}, { value: string }> @observable private _dragging = false; @observable private _iconifying = false; + @observable public Resizing = ""; + constructor(props: Readonly<{}>) { super(props); @@ -260,7 +261,7 @@ export class DocumentDecorations extends React.Component<{}, { value: string }> e.stopPropagation(); if (e.button === 0) { this._isPointerDown = true; - this._resizer = e.currentTarget.id; + this.Resizing = e.currentTarget.id; document.removeEventListener("pointermove", this.onPointerMove); document.addEventListener("pointermove", this.onPointerMove); document.removeEventListener("pointerup", this.onPointerUp); @@ -329,7 +330,7 @@ export class DocumentDecorations extends React.Component<{}, { value: string }> let dX = 0, dY = 0, dW = 0, dH = 0; - switch (this._resizer) { + switch (this.Resizing) { case "": break; case "documentDecorations-topLeftResizer": @@ -402,7 +403,7 @@ export class DocumentDecorations extends React.Component<{}, { value: string }> @action onPointerUp = (e: PointerEvent): void => { e.stopPropagation(); - this._resizer = ""; + this.Resizing = ""; if (e.button === 0) { e.preventDefault(); this._isPointerDown = false; -- cgit v1.2.3-70-g09d2