feat: show top tracks on artist profile with play/shuffle
- Adds extra=topTracks to artist/page API request - Embeds a List::Tracks widget at the top of ArtistView showing the artist's most popular tracks, with Play and Shuffle buttons - Bubbles playTrackRequested through MainContent up to MainWindow - Also adds the viz PCM ring buffer FFI infrastructure (for future spectrum widget) to the Rust backend Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
use anyhow::Result;
|
||||
use rb::RB;
|
||||
use std::io::{self, Read, Seek, SeekFrom};
|
||||
use std::sync::{
|
||||
atomic::{AtomicBool, Ordering},
|
||||
@@ -176,8 +177,12 @@ pub fn play_track_inline(
|
||||
}
|
||||
}
|
||||
if audio_output.is_none() {
|
||||
*audio_output = Some(AudioOutput::try_open(sample_rate, channels)?);
|
||||
let mut ao = AudioOutput::try_open(sample_rate, channels)?;
|
||||
ao.set_viz_producer(status.viz_ring.producer());
|
||||
*audio_output = Some(ao);
|
||||
}
|
||||
status.viz_sample_rate.store(sample_rate, Ordering::Relaxed);
|
||||
status.viz_channels.store(channels as u32, Ordering::Relaxed);
|
||||
let ao = audio_output.as_mut().unwrap();
|
||||
|
||||
let mut stopped = false;
|
||||
|
||||
Reference in New Issue
Block a user