* Initialize window * 初始化窗口
()
| 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 |
no test coverage detected