aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/nodes/DocumentView.tsx
diff options
context:
space:
mode:
authorbobzel <zzzman@gmail.com>2023-06-14 11:03:57 -0400
committerbobzel <zzzman@gmail.com>2023-06-14 11:03:57 -0400
commitd7e2cf07bbfd7f9ed35c42068326d4ea988306bc (patch)
tree83e3eaf041ab773373b923b7cd5a033d1295df9e /src/client/views/nodes/DocumentView.tsx
parentee88a9edb0c68cf99d8aee3ca8a001e5e53a30c2 (diff)
fixed double clicking to not trigger on a document if it is active (previoulsy was if selected)
Diffstat (limited to 'src/client/views/nodes/DocumentView.tsx')
-rw-r--r--src/client/views/nodes/DocumentView.tsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/client/views/nodes/DocumentView.tsx b/src/client/views/nodes/DocumentView.tsx
index 769ba3038..769aff5e2 100644
--- a/src/client/views/nodes/DocumentView.tsx
+++ b/src/client/views/nodes/DocumentView.tsx
@@ -568,7 +568,7 @@ export class DocumentViewInternal extends DocComponent<DocumentViewInternalProps
this.onPointerUpHandler.script.run({ self: this.rootDoc, this: this.layoutDoc }, console.log);
} else if (e.button === 0 && Utils.isClick(e.clientX, e.clientY, this._downX, this._downY, this._downTime)) {
this._doubleTap = (this.onDoubleClickHandler?.script || this.rootDoc.defaultDoubleClick !== 'ignore') && Date.now() - this._lastTap < Utils.CLICK_TIME;
- if (!this.props.isSelected(true)) this._lastTap = Date.now(); // don't want to process the start of a double tap if the doucment is selected
+ if (!this.isContentActive()) this._lastTap = Date.now(); // don't want to process the start of a double tap if the doucment is selected
}
if (DocumentView.LongPress) e.preventDefault();
};