refactor: resync with qbqt baseline and restore genre browser
Some checks failed
Build for Windows / build-windows (push) Has been cancelled
Some checks failed
Build for Windows / build-windows (push) Has been cancelled
This commit is contained in:
@@ -141,7 +141,7 @@ fn player_loop(rx: std::sync::mpsc::Receiver<PlayerCommand>, status: PlayerStatu
|
||||
match rx.recv_timeout(Duration::from_millis(100)) {
|
||||
Ok(PlayerCommand::Play(info)) => break info,
|
||||
Ok(PlayerCommand::QueueNext(info)) => {
|
||||
// If completely idle and get QueueNext, treat as Play
|
||||
// If we are completely idle and get QueueNext, treat as Play
|
||||
break info;
|
||||
}
|
||||
Ok(PlayerCommand::Stop) => {
|
||||
@@ -155,7 +155,7 @@ fn player_loop(rx: std::sync::mpsc::Receiver<PlayerCommand>, status: PlayerStatu
|
||||
Ok(PlayerCommand::SetVolume(v)) => {
|
||||
status.volume.store(v, Ordering::Relaxed);
|
||||
}
|
||||
Ok(_) => {}
|
||||
Ok(_) => {} // Ignore Pause/Resume when idle
|
||||
Err(RecvTimeoutError::Timeout) => {}
|
||||
Err(RecvTimeoutError::Disconnected) => break 'outer,
|
||||
}
|
||||
@@ -176,9 +176,11 @@ fn player_loop(rx: std::sync::mpsc::Receiver<PlayerCommand>, status: PlayerStatu
|
||||
status.position_secs.store(0, Ordering::Relaxed);
|
||||
paused.store(false, Ordering::SeqCst);
|
||||
|
||||
// TrackInfo now directly passes the prefetch_data (if it exists) to the decoder
|
||||
match decoder::play_track_inline(info, &status, &paused, &mut audio_output, &rx) {
|
||||
Ok(Some(NextAction::Play(next_track))) => {
|
||||
pending_action = Some(NextAction::Play(next_track));
|
||||
// Interrupted by a manual play, no need to tell C++ to advance the queue
|
||||
}
|
||||
Ok(Some(NextAction::Transition(next_track))) => {
|
||||
pending_action = Some(NextAction::Play(next_track));
|
||||
|
||||
Reference in New Issue
Block a user