Skip to content

Commit

Permalink
fix: implemented workaround for broken or missing tray icon menu on l…
Browse files Browse the repository at this point in the history
…inux
  • Loading branch information
JarEXE committed Dec 11, 2024
1 parent d8b59ca commit fd8c57b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/main/services/window-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ export class WindowManager {
this.mainWindow?.focus();
}

public static createSystemTray(language: string) {
public static async createSystemTray(language: string) {
let tray: Tray;

if (process.platform === "darwin") {
Expand Down Expand Up @@ -263,6 +263,7 @@ export class WindowManager {
},
]);

tray.setContextMenu(contextMenu);
return contextMenu;
};

Expand All @@ -274,6 +275,8 @@ export class WindowManager {
tray.setToolTip("Hydra");

if (process.platform !== "darwin") {
await updateSystemTray();

tray.addListener("click", () => {
if (this.mainWindow) {
if (
Expand Down

0 comments on commit fd8c57b

Please sign in to comment.