Static title (#17)

This commit is contained in:
Nick 2023-04-19 22:26:56 -04:00 committed by GitHub
parent 4721c46d8c
commit c495e71f35
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 1 deletions

View file

@ -232,6 +232,7 @@ export function createMainWindow() {
}, },
icon: ICON_PATH, icon: ICON_PATH,
frame: VencordSettings.store.frameless !== true, frame: VencordSettings.store.frameless !== true,
...(Settings.store.staticTitle ? { title: "Vencord" } : {}),
...(VencordSettings.store.macosTranslucency ...(VencordSettings.store.macosTranslucency
? { ? {
vibrancy: "sidebar", vibrancy: "sidebar",
@ -250,6 +251,8 @@ export function createMainWindow() {
return false; return false;
}); });
if (Settings.store.staticTitle) win.on("page-title-updated", e => e.preventDefault());
initWindowBoundsListeners(win); initWindowBoundsListeners(win);
if (Settings.store.tray ?? true) initTray(win); if (Settings.store.tray ?? true) initTray(win);
initMenuBar(win); initMenuBar(win);

View file

@ -31,7 +31,8 @@ export default function SettingsUi() {
"openLinksWithElectron", "openLinksWithElectron",
"Open Links in app (experimental)", "Open Links in app (experimental)",
"Opens links in a new Vencord Desktop window instead of your web browser" "Opens links in a new Vencord Desktop window instead of your web browser"
] ],
["staticTitle", "Static Title", 'Makes the window title "Vencord" instead of changing to the current page']
]; ];
return ( return (

View file

@ -17,4 +17,5 @@ export interface Settings {
tray?: boolean; tray?: boolean;
minimizeToTray?: boolean; minimizeToTray?: boolean;
skippedUpdate?: string; skippedUpdate?: string;
staticTitle?: boolean;
} }