diff --git a/src/electron/tray.js b/src/electron/tray.js index ae3152a..d06cfb1 100644 --- a/src/electron/tray.js +++ b/src/electron/tray.js @@ -22,54 +22,26 @@ export function createTray(win) { const contextMenu = Menu.buildFromTemplate([ { label: "播放/暂停", - icon: "src/icon/play.png", click: () => { win.webContents.send("play"); }, }, - { - label: "上一首", - icon: "src/icon/left.png", - accelerator: "CmdOrCtrl+Left", - click: () => { - win.webContents.send("previous"); - }, - }, { label: "下一首", - icon: "src/icon/right.png", accelerator: "CmdOrCtrl+Right", click: () => { win.webContents.send("next"); }, }, - { - label: "循环播放", - icon: "src/icon/repeat.png", - accelerator: "Alt+R", - click: () => { - win.webContents.send("repeat"); - }, - }, - { - label: "加入喜欢", - icon: "src/icon/like.png", - accelerator: "CmdOrCtrl+L", - click: () => { - win.webContents.send("like"); - }, - }, { label: "退出", - icon: "src/icon/exit.png", - accelerator: "CmdOrCtrl+W", click: () => { app.exit(); }, }, ]); - tray.popUpContextMenu(contextMenu); }); return tray; +} diff --git a/src/icon/exit.png b/src/icon/exit.png deleted file mode 100644 index 01e21b2..0000000 Binary files a/src/icon/exit.png and /dev/null differ diff --git a/src/icon/left.png b/src/icon/left.png deleted file mode 100644 index 9e49d7e..0000000 Binary files a/src/icon/left.png and /dev/null differ diff --git a/src/icon/like.png b/src/icon/like.png deleted file mode 100644 index 4bea102..0000000 Binary files a/src/icon/like.png and /dev/null differ diff --git a/src/icon/play.png b/src/icon/play.png deleted file mode 100644 index 90537c8..0000000 Binary files a/src/icon/play.png and /dev/null differ diff --git a/src/icon/repeat.png b/src/icon/repeat.png deleted file mode 100644 index d4c3fc7..0000000 Binary files a/src/icon/repeat.png and /dev/null differ diff --git a/src/icon/right.png b/src/icon/right.png deleted file mode 100644 index 50c2e75..0000000 Binary files a/src/icon/right.png and /dev/null differ