@xeokit/xeokit-sdk 2.3.0-beta-17 → 2.3.0-beta-18
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/dist/xeokit-sdk.cjs.js
CHANGED
|
@@ -12106,34 +12106,27 @@ class Canvas extends Component {
|
|
|
12106
12106
|
|
|
12107
12107
|
let lastParent = null;
|
|
12108
12108
|
|
|
12109
|
-
let tickCount = 0;
|
|
12109
|
+
let tickCount = 0;
|
|
12110
12110
|
|
|
12111
12111
|
this._tick = this.scene.on("tick", () => {
|
|
12112
12112
|
|
|
12113
|
-
tickCount++;
|
|
12113
|
+
tickCount++;
|
|
12114
12114
|
|
|
12115
12115
|
self._canvasSizeChanged = false;
|
|
12116
12116
|
|
|
12117
|
-
if (self.optimizeResizeDetection)
|
|
12118
|
-
|
|
12119
|
-
|
|
12120
|
-
|
|
12121
|
-
return; // chipmunk
|
|
12122
|
-
} // chipmunk
|
|
12117
|
+
if (self.optimizeResizeDetection) {
|
|
12118
|
+
if (tickCount < 10) {
|
|
12119
|
+
return;
|
|
12120
|
+
}
|
|
12123
12121
|
}
|
|
12124
12122
|
|
|
12125
|
-
tickCount = 0;
|
|
12123
|
+
tickCount = 0;
|
|
12126
12124
|
|
|
12127
12125
|
const canvas = this.canvas;
|
|
12128
12126
|
|
|
12129
12127
|
const newResolutionScale = (this._resolutionScale !== lastResolutionScale);
|
|
12130
12128
|
const newWindowSize = (window.innerWidth !== lastWindowWidth || window.innerHeight !== lastWindowHeight);
|
|
12131
12129
|
|
|
12132
|
-
if (!newWindowSize) // chipmunk
|
|
12133
|
-
{ // chipmunk
|
|
12134
|
-
return; // chipmunk
|
|
12135
|
-
} // chipmunk
|
|
12136
|
-
|
|
12137
12130
|
const newCanvasSize = (canvas.clientWidth !== lastCanvasWidth || canvas.clientHeight !== lastCanvasHeight);
|
|
12138
12131
|
const newCanvasPos = (canvas.offsetLeft !== lastCanvasOffsetLeft || canvas.offsetTop !== lastCanvasOffsetTop);
|
|
12139
12132
|
|
package/dist/xeokit-sdk.es.js
CHANGED
|
@@ -12102,34 +12102,27 @@ class Canvas extends Component {
|
|
|
12102
12102
|
|
|
12103
12103
|
let lastParent = null;
|
|
12104
12104
|
|
|
12105
|
-
let tickCount = 0;
|
|
12105
|
+
let tickCount = 0;
|
|
12106
12106
|
|
|
12107
12107
|
this._tick = this.scene.on("tick", () => {
|
|
12108
12108
|
|
|
12109
|
-
tickCount++;
|
|
12109
|
+
tickCount++;
|
|
12110
12110
|
|
|
12111
12111
|
self._canvasSizeChanged = false;
|
|
12112
12112
|
|
|
12113
|
-
if (self.optimizeResizeDetection)
|
|
12114
|
-
|
|
12115
|
-
|
|
12116
|
-
|
|
12117
|
-
return; // chipmunk
|
|
12118
|
-
} // chipmunk
|
|
12113
|
+
if (self.optimizeResizeDetection) {
|
|
12114
|
+
if (tickCount < 10) {
|
|
12115
|
+
return;
|
|
12116
|
+
}
|
|
12119
12117
|
}
|
|
12120
12118
|
|
|
12121
|
-
tickCount = 0;
|
|
12119
|
+
tickCount = 0;
|
|
12122
12120
|
|
|
12123
12121
|
const canvas = this.canvas;
|
|
12124
12122
|
|
|
12125
12123
|
const newResolutionScale = (this._resolutionScale !== lastResolutionScale);
|
|
12126
12124
|
const newWindowSize = (window.innerWidth !== lastWindowWidth || window.innerHeight !== lastWindowHeight);
|
|
12127
12125
|
|
|
12128
|
-
if (!newWindowSize) // chipmunk
|
|
12129
|
-
{ // chipmunk
|
|
12130
|
-
return; // chipmunk
|
|
12131
|
-
} // chipmunk
|
|
12132
|
-
|
|
12133
12126
|
const newCanvasSize = (canvas.clientWidth !== lastCanvasWidth || canvas.clientHeight !== lastCanvasHeight);
|
|
12134
12127
|
const newCanvasPos = (canvas.offsetLeft !== lastCanvasOffsetLeft || canvas.offsetTop !== lastCanvasOffsetTop);
|
|
12135
12128
|
|