mirror of
https://gh.catmak.name/https://github.com/mihomo-party-org/mihomo-party
synced 2025-12-27 05:00:30 +08:00
try to fix macos start
This commit is contained in:
parent
478f9013fc
commit
fc6b86fabc
@ -79,11 +79,13 @@ app.whenReady().then(async () => {
|
|||||||
app.on('activate', function () {
|
app.on('activate', function () {
|
||||||
// On macOS it's common to re-create a window in the app when the
|
// On macOS it's common to re-create a window in the app when the
|
||||||
// dock icon is clicked and there are no other windows open.
|
// dock icon is clicked and there are no other windows open.
|
||||||
if (BrowserWindow.getAllWindows().length === 0) {
|
if (!mainWindow) {
|
||||||
if (destroyTimer) {
|
if (destroyTimer) {
|
||||||
clearTimeout(destroyTimer)
|
clearTimeout(destroyTimer)
|
||||||
}
|
}
|
||||||
createWindow(true)
|
createWindow(true)
|
||||||
|
} else {
|
||||||
|
showMainWindow()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user