0
0
mirror of https://github.com/cucumber-sp/yandex-music-linux.git synced 2024-12-23 22:22:59 +03:00

fix tray icon

This commit is contained in:
Andrey Onishchenko 2024-02-10 19:14:52 +03:00
parent 9b67fe0c60
commit 3eb7fe7816

View File

@ -2,11 +2,13 @@ diff --git a/main/lib/createTray.js b/main/lib/createTray.js
index e69de29..c8b9f0d 100644
--- a/main/lib/createTray.js
+++ b/main/lib/createTray.js
@@ -0,0 +1,17 @@
+const { app, Menu, Tray } = require('electron')
@@ -0,0 +1,19 @@
+const { app, Menu, Tray, nativeImage } = require('electron');
+const path = require('path');
+
+function createTray(window) {
+ const tray = new Tray('build/next-desktop/favicon.png');
+ const iconPath = path.join(__dirname, '../../build/next-desktop/favicon.png');
+ const tray = new Tray(iconPath);
+ const contextMenu = Menu.buildFromTemplate([
+ {label: 'Quit YandexMusic', click: app.quit}
+ ]);