mirror of
https://github.com/ElectronNET/Electron.NET.git
synced 2026-09-22 06:54:44 +00:00
remove listeners on the call to before-quit-for-update
This commit is contained in:
@@ -55,10 +55,13 @@ app.on('will-finish-launching', () => {
|
||||
app.on('before-quit-for-update', () => {
|
||||
ignoreApiProcessClosed = true;
|
||||
|
||||
app.removeAllListeners("window-all-closed");
|
||||
|
||||
const windows = BrowserWindow.getAllWindows();
|
||||
if (windows.length) {
|
||||
windows.forEach(w => {
|
||||
try {
|
||||
w.removeAllListeners("close");
|
||||
w.hide();
|
||||
w.destroy();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user