Explorar o código

add an api function to handle viewer resize

Yana Rose %!s(int64=4) %!d(string=hai) anos
pai
achega
93644ac3f9
Modificáronse 1 ficheiros con 4 adicións e 0 borrados
  1. 4 0
      src/viewer/index.ts

+ 4 - 0
src/viewer/index.ts

@@ -212,4 +212,8 @@ export class Viewer {
     async loadStructureFromData(data: string | number[], format: BuiltInTrajectoryFormat, isBinary: boolean, props?: PresetProps & { dataLabel?: string }, matrix?: Mat4) {
         return this.customState.modelLoader.parse({ data, format, isBinary }, props, matrix);
     }
+
+    handleResize() {
+        this.plugin.layout.events.updated.next();
+    }
 }