Explorar o código

call Canvas3D scene animating by animation manager

David Sehnal %!s(int64=6) %!d(string=hai) anos
pai
achega
a7e4507758
Modificáronse 1 ficheiros con 2 adicións e 0 borrados
  1. 2 0
      src/mol-plugin/state/animation/manager.ts

+ 2 - 0
src/mol-plugin/state/animation/manager.ts

@@ -89,6 +89,7 @@ class PluginAnimationManager extends PluginComponent<PluginAnimationManager.Stat
     }
 
     start() {
+        this.context.canvas3d.setSceneAnimating(true);
         this.updateState({ animationState: 'playing' });
         this.triggerUpdate();
 
@@ -100,6 +101,7 @@ class PluginAnimationManager extends PluginComponent<PluginAnimationManager.Stat
     }
 
     stop() {
+        this.context.canvas3d.setSceneAnimating(false);
         if (typeof this._frame !== 'undefined') cancelAnimationFrame(this._frame);
         this.updateState({ animationState: 'stopped' });
         this.triggerUpdate();