set timeout can go away now
This commit is contained in:
parent
c410809b68
commit
23b6033432
2 changed files with 68 additions and 59 deletions
|
@ -919,6 +919,12 @@ const app = new Vue({
|
|||
}
|
||||
});
|
||||
|
||||
this.mk.addEventListener(MusicKit.Events.playbackProgressDidChange, () => {
|
||||
if (self.mk.currentPlaybackProgress === (app.cfg.connectivity.lastfm.scrobble_after / 100)) {
|
||||
ipcRenderer.send('lastfm:scrobbleTrack', MusicKitInterop.getAttributes());
|
||||
}
|
||||
})
|
||||
|
||||
this.mk.addEventListener(MusicKit.Events.playbackStateDidChange, (event) => {
|
||||
ipcRenderer.send('wsapi-updatePlaybackState', wsapi.getAttributes());
|
||||
document.body.setAttribute("playback-state", event.state == 2 ? "playing" : "paused")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue