修复dock栏点击

master 2.0.0
宇天 2020-12-12 19:32:13 +08:00
parent 1fb6b67fa8
commit 17c2d8a850
1 changed files with 7 additions and 0 deletions

View File

@ -103,6 +103,13 @@ app.once('ready', () => {
app.__float__ = null app.__float__ = null
app.exit() app.exit()
}) })
// mac专属事件,点击dock栏图标,可激活窗口
app.on('activate', _ => {
if (app.__main__) {
app.__main__.restore()
}
})
}) })
ipcMain.on('app', (ev, conn) => { ipcMain.on('app', (ev, conn) => {