aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/collections
diff options
context:
space:
mode:
authorGeireann Lindfield Roberts <60007097+geireann@users.noreply.github.com>2022-07-01 12:20:19 -0700
committerGeireann Lindfield Roberts <60007097+geireann@users.noreply.github.com>2022-07-01 12:20:19 -0700
commit2e95a659dfaa37ecdea89866a8df3d4f9bbdecfe (patch)
treef92d8a74854748d12016209a208aa35331761fbc /src/client/views/collections
parentda19cbc10d28b2e39a6592b80880106a415acc1c (diff)
parent9da331c1a430625b136acbaa515d33448f96d495 (diff)
Merge branch 'master' into geireann-eslint-prettier
Diffstat (limited to 'src/client/views/collections')
-rw-r--r--src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx19
1 files changed, 11 insertions, 8 deletions
diff --git a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx
index d33f0b5be..8444c9119 100644
--- a/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx
+++ b/src/client/views/collections/collectionFreeForm/CollectionFreeFormView.tsx
@@ -17,7 +17,6 @@ import { TraceMobx } from '../../../../fields/util';
import { GestureUtils } from '../../../../pen-gestures/GestureUtils';
import { aggregateBounds, emptyFunction, intersectRect, returnFalse, setupMoveUpEvents, Utils } from '../../../../Utils';
import { CognitiveServices } from '../../../cognitive_services/CognitiveServices';
-import { DocServer } from '../../../DocServer';
import { Docs, DocUtils } from '../../../documents/Documents';
import { DocumentType } from '../../../documents/DocumentTypes';
import { CurrentUserUtils } from '../../../util/CurrentUserUtils';
@@ -25,10 +24,8 @@ import { DocumentManager } from '../../../util/DocumentManager';
import { DragManager, dropActionType } from '../../../util/DragManager';
import { HistoryUtil } from '../../../util/History';
import { InteractionUtils } from '../../../util/InteractionUtils';
-import { LinkManager } from '../../../util/LinkManager';
import { RecordingApi } from '../../../util/RecordingApi';
import { ScriptingGlobals } from '../../../util/ScriptingGlobals';
-import { SearchUtil } from '../../../util/SearchUtil';
import { SelectionManager } from '../../../util/SelectionManager';
import { ColorScheme } from '../../../util/SettingsManager';
import { SnappingManager } from '../../../util/SnappingManager';
@@ -59,6 +56,8 @@ import './CollectionFreeFormView.scss';
import { MarqueeView } from './MarqueeView';
import React = require('react');
import e = require('connect-flash');
+import { ReplayMovements } from '../../../util/ReplayMovements';
+
export type collectionFreeformViewProps = {
annotationLayerHostsContent?: boolean; // whether to force scaling of content (needed by ImageBox)
@@ -1080,11 +1079,15 @@ export class CollectionFreeFormView extends CollectionSubView<Partial<collection
Doc.UserDoc()?.presentationMode === 'recording' && RecordingApi.Instance.setRecordingFFView(this);
// TODO: make this based off the specific recording FFView
Doc.UserDoc()?.presentationMode === 'none' && RecordingApi.Instance.setPlayFFView(this);
- if (Doc.UserDoc()?.presentationMode === 'watching') {
- RecordingApi.Instance.pauseVideoAndMovements();
- Doc.UserDoc().presentationMode = 'none';
- // RecordingApi.Instance.pauseMovements()
- }
+
+ // TODO: zzz + michael to figure out this merge in case of strange behaviour
+ // if (Doc.UserDoc()?.presentationMode === 'watching') {
+ // RecordingApi.Instance.pauseVideoAndMovements();
+ // Doc.UserDoc().presentationMode = 'none';
+ // // RecordingApi.Instance.pauseMovements()
+ // }
+ // this is the easiest way to do this -> will talk with Bob about using mobx to do this to remove this line of code.
+ if (Doc.UserDoc()?.presentationMode === 'watching') ReplayMovements.Instance.pauseFromInteraction();
if (!this.isAnnotationOverlay && clamp) {
// this section wraps the pan position, horizontally and/or vertically whenever the content is panned out of the viewing bounds