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

Method hidePopup

packages/fairygui/src/core/GRoot.ts:142–156  ·  view source on GitHub ↗

* Hide popup * 隐藏弹出窗口

(popup?: GObject)

Source from the content-addressed store, hash-verified

140 * 隐藏弹出窗口
141 */
142 public hidePopup(popup?: GObject): void {
143 if (popup) {
144 const index = this._popupStack.indexOf(popup);
145 if (index !== -1) {
146 this._popupStack.splice(index, 1);
147 this.closePopup(popup);
148 }
149 } else {
150 // Hide all popups
151 for (const p of this._popupStack) {
152 this.closePopup(p);
153 }
154 this._popupStack.length = 0;
155 }
156 }
157
158 private closePopup(popup: GObject): void {
159 popup.visible = false;

Callers 3

togglePopupMethod · 0.95
onStageMouseDownMethod · 0.95
handleItemClickMethod · 0.80

Calls 1

closePopupMethod · 0.95

Tested by

no test coverage detected