Skip to content

Commit 7b0a5c2

Browse files
fix(main): destroy window in windows & linux #570 (#572)
1 parent 9ac6811 commit 7b0a5c2

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/index.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,13 @@ function createWindow() {
5858
mainWindow.on('close', (event) => {
5959
store.app.set('bounds', mainWindow.getBounds())
6060

61-
if (!isQuitting) {
61+
if (process.platform === 'darwin' && !isQuitting) {
6262
event.preventDefault()
6363
mainWindow.hide()
64+
return
6465
}
65-
else {
66-
mainWindow.destroy()
67-
}
66+
67+
mainWindow.destroy()
6868
})
6969
}
7070

0 commit comments

Comments
 (0)