refactor
This commit is contained in:
parent
5fed84c04d
commit
4fb6d8d872
1 changed files with 2 additions and 6 deletions
|
@ -274,12 +274,8 @@ function createMainWindow() {
|
||||||
win.setMenuBarVisibility(false);
|
win.setMenuBarVisibility(false);
|
||||||
|
|
||||||
win.on("close", e => {
|
win.on("close", e => {
|
||||||
if (
|
const useTray = Settings.store.minimizeToTray && Settings.store.tray;
|
||||||
isQuitting ||
|
if (isQuitting || (process.platform !== "darwin" && !useTray)) return;
|
||||||
(process.platform !== "darwin" &&
|
|
||||||
(Settings.store.minimizeToTray === false || Settings.store.tray === false))
|
|
||||||
)
|
|
||||||
return;
|
|
||||||
|
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
|
||||||
|
|
Reference in a new issue