Explorar o código

Merge branch 'master' of https://github.com/BabylonJS/Babylon.js

David Catuhe %!s(int64=6) %!d(string=hai) anos
pai
achega
e80d2e57c4
Modificáronse 2 ficheiros con 5 adicións e 1 borrados
  1. 4 0
      Playground/js/main.js
  2. 1 1
      Playground/js/settingsPG.js

+ 4 - 0
Playground/js/main.js

@@ -631,6 +631,10 @@ class Main {
         this.parent.monacoCreator.JsEditor.focus();
     };
 
+    compileAndRunFromOutside() {
+        compileAndRun(this.parent, this.fpsLabel);
+    };
+
     checkSafeMode(message) {
         if (document.getElementById("safemodeToggle" + this.parent.utils.getCurrentSize()) &&
             document.getElementById("safemodeToggle" + this.parent.utils.getCurrentSize()).classList.contains('checked')) {

+ 1 - 1
Playground/js/settingsPG.js

@@ -163,7 +163,7 @@ class SettingsPG {
                 localStorage.removeItem("bjs-playground-apiversion");
                 localStorage.removeItem("bjs-playground-apiversion-tempcode");
 
-                this.parent.main.compileAndRun();
+                this.parent.main.compileAndRunFromOutside();
             }.bind(this);
 
             document.head.appendChild(newBJSscript);