瀏覽代碼

StructureHierarchyManager tweak

David Sehnal 5 年之前
父節點
當前提交
d03a442b6c
共有 1 個文件被更改,包括 4 次插入0 次删除
  1. 4 0
      src/mol-plugin-state/manager/structure.ts

+ 4 - 0
src/mol-plugin-state/manager/structure.ts

@@ -34,6 +34,10 @@ export class StructureHierarchyManager {
             newCurrent.push(ref);
         }
 
+        if (newCurrent.length === 0 && hierarchy.trajectories[0]?.models) {
+            this.behaviors.currentModels.next(hierarchy.trajectories[0]?.models);
+        }
+
         this.behaviors.currentModels.next(newCurrent);
     }