aboutsummaryrefslogtreecommitdiff
path: root/src/client/util/DragManager.ts
diff options
context:
space:
mode:
authorMichael Foiani <sotech117@michaels-mbp-5.devices.brown.edu>2022-06-02 15:33:26 -0400
committerMichael Foiani <sotech117@michaels-mbp-5.devices.brown.edu>2022-06-02 15:33:26 -0400
commit43361401c1e963408bc502bad8f53da82498ceec (patch)
tree9983d2bb633dfed8abe34e02a8d6e310fde81c97 /src/client/util/DragManager.ts
parente6d508b4e1cfe2e7a948bc0399dc5e0e85be8f59 (diff)
parent560d7090702c3559724420f3571b11d86c930177 (diff)
merge with presentmode
Diffstat (limited to 'src/client/util/DragManager.ts')
-rw-r--r--src/client/util/DragManager.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/client/util/DragManager.ts b/src/client/util/DragManager.ts
index 9f8c49081..f438a8c11 100644
--- a/src/client/util/DragManager.ts
+++ b/src/client/util/DragManager.ts
@@ -210,6 +210,10 @@ export namespace DragManager {
options?: DragOptions,
dropEvent?: () => any
) {
+ // stop an 'accidental' on-click drag that may have occured if the user is in presenting mode
+ // note: dragData.dropAction is only undefined when the element itself being dragged without being selected
+ if (Doc.UserDoc()?.presentationMode === 'recording' && dragData.dropAction === undefined) return false;
+
const addAudioTag = (dropDoc: any) => {
dropDoc && !dropDoc.creationDate && (dropDoc.creationDate = new DateField);
dropDoc instanceof Doc && DocUtils.MakeLinkToActiveAudio(() => dropDoc);