@babylonjs/core
Version:
Getting started? Play directly with the Babylon.js API using our [playground](https://playground.babylonjs.com/). It also contains a lot of samples to learn how to use it.
48 lines • 1.5 kB
JavaScript
import { IsWindowObjectExist } from "../../Misc/domManagement.js";
import { AbstractEngine } from "../abstractEngine.js";
AbstractEngine.prototype.displayLoadingUI = function () {
if (!IsWindowObjectExist()) {
return;
}
const loadingScreen = this.loadingScreen;
if (loadingScreen) {
loadingScreen.displayLoadingUI();
}
};
AbstractEngine.prototype.hideLoadingUI = function () {
if (!IsWindowObjectExist()) {
return;
}
const loadingScreen = this._loadingScreen;
if (loadingScreen) {
loadingScreen.hideLoadingUI();
}
};
Object.defineProperty(AbstractEngine.prototype, "loadingScreen", {
get: function () {
if (!this._loadingScreen && this._renderingCanvas) {
this._loadingScreen = AbstractEngine.DefaultLoadingScreenFactory(this._renderingCanvas);
}
return this._loadingScreen;
},
set: function (value) {
this._loadingScreen = value;
},
enumerable: true,
configurable: true,
});
Object.defineProperty(AbstractEngine.prototype, "loadingUIText", {
set: function (value) {
this.loadingScreen.loadingUIText = value;
},
enumerable: true,
configurable: true,
});
Object.defineProperty(AbstractEngine.prototype, "loadingUIBackgroundColor", {
set: function (value) {
this.loadingScreen.loadingUIBackgroundColor = value;
},
enumerable: true,
configurable: true,
});
//# sourceMappingURL=abstractEngine.loadingScreen.js.map