From 14c71aeae382aec622c3bed083bc90872e447152 Mon Sep 17 00:00:00 2001 From: TheGoddessInari Date: Wed, 23 Jan 2019 11:59:22 -0800 Subject: [PATCH] Partially revert da64582cf3c0026a1b06b3a936f813d9b629a220. App.quit should work again. --- electron/main.js | 8 ++++---- electron/menu.js | 4 ++-- electron/tray.js | 2 +- masterpassword.html | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/electron/main.js b/electron/main.js index d9d897e0..7664f173 100644 --- a/electron/main.js +++ b/electron/main.js @@ -187,7 +187,7 @@ function createWindow () { mainWindow.minimize(); break; case 'quit': - app.exit(); + app.quit(); break; } break; @@ -309,7 +309,7 @@ ipcMain.on('reloadApp', function(event) { // Relaunch app ipcMain.on('relaunchApp', function(event) { app.relaunch(); - app.exit(0); + app.quit(0); }); const haveLock = app.requestSingleInstanceLock(); @@ -325,7 +325,7 @@ app.on('second-instance', (commandLine, workingDirectory) => { }); if (!haveLock) { - app.exit(); + app.quit(); } // Code for downloading images as temporal files @@ -450,7 +450,7 @@ app.on('window-all-closed', function () { // On OS X it is common for applications and their menu bar // to stay active until the user quits explicitly with Cmd + Q if (process.platform !== 'darwin') { - app.exit(); + app.quit(); } }); diff --git a/electron/menu.js b/electron/menu.js index 13d8a548..77f647a7 100644 --- a/electron/menu.js +++ b/electron/menu.js @@ -323,7 +323,7 @@ module.exports = function(config) { { label: locale['tray[1]'], click() { - app.exit(); + app.quit(); } } ] @@ -345,7 +345,7 @@ module.exports = function(config) { label: locale['menu.file[1]'], accelerator: 'CmdOrCtrl+Shift+Q', click() { - app.exit(); + app.quit(); } } ] diff --git a/electron/tray.js b/electron/tray.js index aef171c3..2c5c1fc9 100644 --- a/electron/tray.js +++ b/electron/tray.js @@ -27,7 +27,7 @@ exports.create = function(win, config) { { label: locale['tray[1]'], click() { - app.exit(); + app.quit(); } } ]); diff --git a/masterpassword.html b/masterpassword.html index 56f1fd7d..20cde1ab 100644 --- a/masterpassword.html +++ b/masterpassword.html @@ -25,7 +25,7 @@ return doValidate({ keyCode: 13 }, document.getElementsByTagName('input')[0].value); } function exit() { - require('electron').remote.app.exit(); + require('electron').remote.app.quit(); }