MCPcopy Create free account
hub / github.com/esengine/esengine / init

Method init

packages/fairygui/src/widgets/Window.ts:398–419  ·  view source on GitHub ↗

* Initialize window * 初始化窗口

()

Source from the content-addressed store, hash-verified

396 * 初始化窗口
397 */
398 public init(): void {
399 if (this._inited || this._loading) {
400 return;
401 }
402
403 if (this._uiSources.length > 0) {
404 this._loading = false;
405
406 for (const source of this._uiSources) {
407 if (!source.loaded) {
408 source.load(this.onUILoadComplete.bind(this), this);
409 this._loading = true;
410 }
411 }
412
413 if (!this._loading) {
414 this.doInit();
415 }
416 } else {
417 this.doInit();
418 }
419 }
420
421 /**
422 * Called when window is initialized

Callers 1

onWindowShownMethod · 0.95

Calls 3

doInitMethod · 0.95
loadMethod · 0.65
bindMethod · 0.45

Tested by

no test coverage detected