diff --git a/app/index.ts b/app/index.ts index c629689a..f874dbf6 100644 --- a/app/index.ts +++ b/app/index.ts @@ -164,12 +164,6 @@ app.on('ready', () => windowSet.delete(hwin); }); - hwin.on('closed', () => { - if (process.platform !== 'darwin' && windowSet.size === 0) { - app.quit(); - } - }); - return hwin; } @@ -188,6 +182,12 @@ app.on('ready', () => } }); + app.on('window-all-closed', () => { + if (process.platform !== 'darwin') { + app.quit(); + } + }); + const makeMenu = () => { const menu = plugins.decorateMenu(AppMenu.createMenu(createWindow, plugins.getLoadedPluginVersions));