mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-11 10:31:47 +00:00
resolve merge error
This commit is contained in:
@ -1,43 +0,0 @@
|
|||||||
const { Menu, app } = require("electron");
|
|
||||||
const { setApplicationMenu } = require("../../../menu");
|
|
||||||
const config = require("../../../config");
|
|
||||||
|
|
||||||
module.exports = (win, options, setOptions, togglePip, isInPip) => {
|
|
||||||
if (isInPip) {
|
|
||||||
Menu.setApplicationMenu(Menu.buildFromTemplate([
|
|
||||||
{
|
|
||||||
label: "App",
|
|
||||||
submenu: [
|
|
||||||
{
|
|
||||||
label: "Exit Picture in Picture",
|
|
||||||
click: togglePip,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: "Always on top",
|
|
||||||
type: "checkbox",
|
|
||||||
checked: options.alwaysOnTop,
|
|
||||||
click: (item) => {
|
|
||||||
setOptions({ alwaysOnTop: item.checked });
|
|
||||||
win.setAlwaysOnTop(item.checked);
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
label: "Restart",
|
|
||||||
click: () => {
|
|
||||||
app.relaunch();
|
|
||||||
app.quit();
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{ role: "quit" },
|
|
||||||
],
|
|
||||||
},
|
|
||||||
]));
|
|
||||||
if (config.get("options.hideMenu")) {
|
|
||||||
setImmediate(() => {
|
|
||||||
win.webContents.send("toggleMenu");
|
|
||||||
});
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
setApplicationMenu(win);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
Reference in New Issue
Block a user