Code style
This commit is contained in:
parent
16e70e553a
commit
0041c385bc
14
main.js
14
main.js
|
@ -82,14 +82,12 @@ function createWindow () {
|
||||||
|
|
||||||
// Handle shutdown event on Mac with minimizeOnClose
|
// Handle shutdown event on Mac with minimizeOnClose
|
||||||
// to prevent shutdown interrupt
|
// to prevent shutdown interrupt
|
||||||
if (isMac) {
|
if (isMac && minimizeOnClose) {
|
||||||
if (minimizeOnClose) {
|
const { powerMonitor } = require('electron')
|
||||||
const { powerMonitor } = require('electron')
|
powerMonitor.on('shutdown', () => {
|
||||||
powerMonitor.on('shutdown', () => {
|
app.isQuitting = true
|
||||||
app.isQuitting = true
|
app.quit()
|
||||||
app.quit()
|
})
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Save window size
|
// Save window size
|
||||||
|
|
Loading…
Reference in New Issue