@netless/window-manager 0.3.16-canary.1 → 0.3.16-canary.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@netless/window-manager",
3
- "version": "0.3.16-canary.1",
3
+ "version": "0.3.16-canary.2",
4
4
  "description": "",
5
5
  "main": "dist/index.es.js",
6
6
  "module": "dist/index.es.js",
package/src/MainView.ts CHANGED
@@ -24,6 +24,9 @@ export class MainViewProxy extends Base {
24
24
  emitter.once("mainViewMounted").then(() => {
25
25
  setTimeout(() => {
26
26
  this.start();
27
+ if (!this.mainViewCamera || !this.mainViewSize) {
28
+ this.setCameraAndSize();
29
+ }
27
30
  }, 200); // 等待 mainView 挂载完毕再进行监听,否则会触发不必要的 onSizeUpdated
28
31
  });
29
32
  emitter.on("playgroundSizeChange", () => {
package/src/index.ts CHANGED
@@ -176,7 +176,7 @@ export class WindowManager extends InvisiblePlugin<WindowMangerAttributes> {
176
176
  public static containerSizeRatio = DEFAULT_CONTAINER_RATIO;
177
177
  private static isCreated = false;
178
178
 
179
- public version = "0.3.16-canary.1";
179
+ public version = "0.3.16-canary.2";
180
180
 
181
181
  public appListeners?: AppListeners;
182
182