Skip to content

Commit

Permalink
don't disable tray 'Open' item when window is shown (doesnt work corr…
Browse files Browse the repository at this point in the history
…ectly)
  • Loading branch information
Vendicated committed Jan 16, 2024
1 parent 2e4c834 commit 83e74b9
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions src/main/mainWindow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,7 @@ function initTray(win: BrowserWindow) {
label: "Open",
click() {
win.show();
},
enabled: false
}
},
{
label: "About",
Expand Down Expand Up @@ -122,14 +121,6 @@ function initTray(win: BrowserWindow) {
tray.setToolTip("Vesktop");
tray.setContextMenu(trayMenu);
tray.on("click", () => win.show());

win.on("show", () => {
trayMenu.items[0].enabled = false;
});

win.on("hide", () => {
trayMenu.items[0].enabled = true;
});
}

async function clearData(win: BrowserWindow) {
Expand Down

0 comments on commit 83e74b9

Please sign in to comment.