Commit 45f6129a authored by Max Kellermann's avatar Max Kellermann

player/Control: don't stop playback in Play()

Instead of stopping playback completely, only CANCEL the queued song if necessary, and use the SEEK command to play the selected song. SEEK will take care for current playback state.
parent f3503e00
......@@ -55,15 +55,7 @@ PlayerControl::Play(DetachedSong *song)
assert(song != nullptr);
const ScopeLock protect(mutex);
if (state != PlayerState::STOP)
SynchronousCommand(PlayerCommand::STOP);
assert(next_song == nullptr);
EnqueueSongLocked(song);
assert(next_song == nullptr);
SeekLocked(song, SongTime::zero(), IgnoreError());
}
void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment