mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-11 10:31:47 +00:00
fix custom titlebar in prompt options
This commit is contained in:
@ -1,17 +1,18 @@
|
|||||||
const path = require("path");
|
const path = require("path");
|
||||||
const is = require("electron-is");
|
const is = require("electron-is");
|
||||||
|
const { isEnabled } = require("../config/plugins");
|
||||||
|
|
||||||
const iconPath = path.join(__dirname, "..", "assets", "youtube-music-tray.png");
|
const iconPath = path.join(__dirname, "..", "assets", "youtube-music-tray.png");
|
||||||
const customTitlebarPath = path.join(__dirname, "prompt-custom-titlebar.js");
|
const customTitlebarPath = path.join(__dirname, "prompt-custom-titlebar.js");
|
||||||
|
|
||||||
const promptOptions = is.macOS() ? {
|
const promptOptions = !is.macOS() && isEnabled("in-app-menu") ? {
|
||||||
customStylesheet: "dark",
|
|
||||||
icon: iconPath
|
|
||||||
} : {
|
|
||||||
customStylesheet: "dark",
|
customStylesheet: "dark",
|
||||||
// The following are used for custom titlebar
|
// The following are used for custom titlebar
|
||||||
frame: false,
|
frame: false,
|
||||||
customScript: customTitlebarPath,
|
customScript: customTitlebarPath,
|
||||||
|
} : {
|
||||||
|
customStylesheet: "dark",
|
||||||
|
icon: iconPath
|
||||||
};
|
};
|
||||||
|
|
||||||
module.exports = () => promptOptions;
|
module.exports = () => promptOptions;
|
||||||
|
|||||||
Reference in New Issue
Block a user