mirror of
https://github.com/Mastermindzh/tidal-hifi.git
synced 2025-09-14 15:49:18 +02:00
Compare commits
2 Commits
5.18.0
...
6e359170f9
Author | SHA1 | Date | |
---|---|---|---|
|
6e359170f9 | ||
|
456727c0e0 |
@@ -28,6 +28,7 @@ let currentListenBrainzDelayId: ReturnType<typeof setTimeout>;
|
||||
let scrobbleWaitingForDelay = false;
|
||||
let wasJustPausedOrResumed = false;
|
||||
let currentMediaInfo: Options;
|
||||
let currentNotification: Electron.Notification;
|
||||
|
||||
const elements = {
|
||||
play: '*[data-test="play"]',
|
||||
@@ -359,7 +360,9 @@ function updateMediaInfo(options: Options, notify: boolean) {
|
||||
currentMediaInfo = options;
|
||||
ipcRenderer.send(globalEvents.updateInfo, options);
|
||||
if (settingsStore.get(settings.notifications) && notify) {
|
||||
new Notification({ title: options.title, body: options.artists, icon: options.icon }).show();
|
||||
if (currentNotification) currentNotification.close();
|
||||
currentNotification = new Notification({ title: options.title, body: options.artists, icon: options.icon });
|
||||
currentNotification.show();
|
||||
}
|
||||
updateMpris(options);
|
||||
updateListenBrainz(options);
|
||||
|
Reference in New Issue
Block a user