MCPcopy Create free account
hub / github.com/chieapp/chie / removeWindow

Method removeWindow

src/controller/window-manager.ts:109–118  ·  view source on GitHub ↗
(win: BaseWindow)

Source from the content-addressed store, hash-verified

107 }
108
109 removeWindow(win: BaseWindow) {
110 this.windows.splice(this.windows.indexOf(win), 1);
111 if (this.windows.length == 0)
112 this.#onAllWindowsClosed();
113 // A closed window usually has a large chunk of memory to recycle.
114 collectGarbage();
115 // The |removeWindow| might be called before window saves states, delay a
116 // tick to ensure we have the state.
117 setImmediate(() => this.saveConfig());
118 }
119
120 #onAllWindowsClosed() {
121 if (!this.quitOnAllWindowsClosed)

Callers 1

constructorMethod · 0.80

Calls 2

#onAllWindowsClosedMethod · 0.95
collectGarbageFunction · 0.90

Tested by

no test coverage detected