Procházet zdrojové kódy

Canvas2D: fix WSC visibility issue

Loïc Baumann před 8 roky
rodič
revize
ac8f632bf8

+ 3 - 0
canvas2D/src/Engine/babylon.canvas2d.ts

@@ -1892,6 +1892,9 @@
             }
 
             this.propertyChanged.add((e, st) => {
+                if (e.propertyName !== "isVisible") {
+                    return;
+                }
                 let mesh = this._worldSpaceNode as AbstractMesh;
                 if (mesh) {
                     mesh.isVisible = e.newValue;

+ 3 - 0
dist/preview release/canvas2D/babylon.canvas2d.js

@@ -16432,6 +16432,9 @@ var BABYLON;
                 _this.applyCachedTexture(null, null);
             }
             _this.propertyChanged.add(function (e, st) {
+                if (e.propertyName !== "isVisible") {
+                    return;
+                }
                 var mesh = _this._worldSpaceNode;
                 if (mesh) {
                     mesh.isVisible = e.newValue;

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 2 - 2
dist/preview release/canvas2D/babylon.canvas2d.min.js