Skip to content

Commit

Permalink
fix(tuna): handle playPaused (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
JellyBrick authored Aug 29, 2023
1 parent f2149e3 commit 2f73548
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions plugins/tuna-obs/back.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ module.exports = async (win) => {
data.progress = secToMilisec(t);
post(data);
});
ipcMain.on('playPaused', (_, { isPaused, elapsedSeconds }) => {
if (!data.title) return;
data.status = isPaused ? 'stopped' : 'playing';
data.progress = secToMilisec(elapsedSeconds);
post(data);
});

registerCallback((songInfo) => {
if (!songInfo.title && !songInfo.artist) {
Expand Down

0 comments on commit 2f73548

Please sign in to comment.