mirror of
https://github.com/th-ch/youtube-music.git
synced 2026-01-13 11:21:46 +00:00
feat: add custom window title option (#3656)
This commit is contained in:
@ -599,6 +599,15 @@ app.once('browser-window-created', (_event, win) => {
|
||||
win.webContents.on('will-prevent-unload', (event) => {
|
||||
event.preventDefault();
|
||||
});
|
||||
|
||||
const customWindowTitle = config.get('options.customWindowTitle');
|
||||
|
||||
if (customWindowTitle) {
|
||||
win.on('page-title-updated', (event) => {
|
||||
event.preventDefault();
|
||||
win.setTitle(customWindowTitle);
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
app.on('window-all-closed', () => {
|
||||
|
||||
Reference in New Issue
Block a user