always switch to newly playing mpris session

This commit is contained in:
Damocles 2026-04-18 13:20:52 +02:00
parent c52886f061
commit 381ceaa642

View file

@ -89,8 +89,8 @@ QtObject {
times[identity] = Date.now(); times[identity] = Date.now();
_lastPlayedTime = times; _lastPlayedTime = times;
// If current player is not playing, switch to this one // Always switch to the newly playing player
if (player !== p && player?.playbackState !== MprisPlaybackState.Playing) { if (player !== p) {
const idx = players.indexOf(p); const idx = players.indexOf(p);
if (idx >= 0) { if (idx >= 0) {
playerIdx = idx; playerIdx = idx;