make show window behaving a little better

This commit is contained in:
Johannes Millan 2017-04-30 18:42:46 +02:00
parent f0b8ed36b4
commit 9c19a65e4a

View file

@ -129,7 +129,7 @@ function createWindow() {
}
function showApp() {
mainWin.show();
showOrFocus(mainWin);
}
function quitApp() {
app.isQuiting = true;
@ -142,6 +142,10 @@ function showOrFocus(win) {
} else {
win.show();
}
setTimeout(() => {
win.focus();
}, 60);
}
// Make it a single instance