From 347e8e2bd32854b36828b7bcc645c9c361204251 Mon Sep 17 00:00:00 2001 From: bobzel Date: Wed, 14 Jun 2023 09:12:33 -0400 Subject: fixes after merge of advanced trails --- src/client/views/StyleProvider.tsx | 4 ++-- src/client/views/nodes/trails/PresBox.tsx | 3 ++- src/client/views/nodes/trails/PresElementBox.tsx | 5 +++-- 3 files changed, 7 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/client/views/StyleProvider.tsx b/src/client/views/StyleProvider.tsx index 9199bf931..5eabf21fc 100644 --- a/src/client/views/StyleProvider.tsx +++ b/src/client/views/StyleProvider.tsx @@ -240,12 +240,12 @@ export function DefaultStyleProvider(doc: Opt, props: Opt() { // before moving onto next slide, run the subroutines :) const currentDoc = this.childDocs[this.itemIndex]; - this.runSubroutines(currentDoc.getChildrenToRun?.(), this.childDocs[this.itemIndex + 1]); + this.runSubroutines(TreeView.GetRunningChildren.get(currentDoc)?.(), this.childDocs[this.itemIndex + 1]); this.nextSlide(curLast + 1 === this.childDocs.length ? (this.layoutDoc.presLoop ? 0 : curLast) : curLast + 1); progressiveReveal(true); // shows first progressive document, but without a transition effect diff --git a/src/client/views/nodes/trails/PresElementBox.tsx b/src/client/views/nodes/trails/PresElementBox.tsx index cac6cdd04..a98db3d66 100644 --- a/src/client/views/nodes/trails/PresElementBox.tsx +++ b/src/client/views/nodes/trails/PresElementBox.tsx @@ -25,6 +25,7 @@ import { PresBox } from './PresBox'; import './PresElementBox.scss'; import { PresMovement } from './PresEnums'; import React = require('react'); +import { TreeView } from '../../collections/TreeView'; /** * This class models the view a document added to presentation will have in the presentation. * It involves some functionality for its buttons and options. @@ -178,7 +179,7 @@ export class PresElementBox extends ViewBoxBaseComponent() { e.stopPropagation(); e.preventDefault(); this.presBoxView?.modifierSelect(this.rootDoc, this._itemRef.current!, this._dragRef.current!, e.shiftKey || e.ctrlKey || e.metaKey, e.ctrlKey || e.metaKey, e.shiftKey); - // this.presBoxView?.activeItem && this.showRecording(this.presBoxView?.activeItem); + this.presBoxView?.activeItem && this.showRecording(this.presBoxView?.activeItem); }); } }; @@ -402,7 +403,7 @@ export class PresElementBox extends ViewBoxBaseComponent() { console.log('lfg called'); // TODO: fix this bug const { toggleChildrenRun } = this.rootDoc; - toggleChildrenRun?.(); + TreeView.ToggleChildrenRun.get(this.rootDoc)?.(); // call this.rootDoc.recurChildren() to get all the children // if (iconClick) PresElementBox.showVideo = false; -- cgit v1.2.3-70-g09d2