* Bring window to front * 将窗口置于最前
(win: GObject)
| 346 | * 将窗口置于最前 |
| 347 | */ |
| 348 | public bringToFront(win: GObject): void { |
| 349 | const cnt = this.numChildren; |
| 350 | let i: number; |
| 351 | if (this._modalLayer && this._modalLayer.parent === this) { |
| 352 | i = this.getChildIndex(this._modalLayer); |
| 353 | } else { |
| 354 | i = cnt - 1; |
| 355 | } |
| 356 | |
| 357 | const index = this.getChildIndex(win); |
| 358 | if (index < i) { |
| 359 | this.setChildIndex(win, i); |
| 360 | } |
| 361 | } |
| 362 | |
| 363 | /** |
| 364 | * Get top window |
nothing calls this directly
no test coverage detected