diff --git a/src/renderer/store/player.store.ts b/src/renderer/store/player.store.ts index 1eb67a4e3..391ba62a0 100644 --- a/src/renderer/store/player.store.ts +++ b/src/renderer/store/player.store.ts @@ -167,6 +167,7 @@ export const usePlayerStoreBase = create()( state.player.index = 0; state.player.status = PlayerStatus.PLAYING; state.player.playerNum = 1; + state.player.timestamp = 0; state.queue.default = newUniqueIds; if (state.player.shuffle === PlayerShuffle.TRACK) { @@ -245,6 +246,7 @@ export const usePlayerStoreBase = create()( state.queue.default = []; state.player.status = PlayerStatus.PLAYING; state.player.playerNum = 1; + state.player.timestamp = 0; // Add the first item after the current playing track @@ -569,6 +571,7 @@ export const usePlayerStoreBase = create()( set((state) => { state.player.index = Math.min(queue.items.length - 1, currentIndex + 1); state.player.playerNum = 1; + state.player.timestamp = 0; }); }, mediaPause: () => { @@ -585,6 +588,7 @@ export const usePlayerStoreBase = create()( if (index !== -1) { state.player.index = index; + state.player.timestamp = 0; } } @@ -597,6 +601,7 @@ export const usePlayerStoreBase = create()( set((state) => { // Only decrement if we're not at the start state.player.index = Math.max(0, currentIndex - 1); + state.player.timestamp = 0; }); }, mediaSeekToTimestamp: (timestamp: number) => {