wip: refactor pt.36 (10e) fewer structs, more field duplication

This commit is contained in:
🪞👃🪞 2024-11-15 02:21:30 +01:00
parent 7af5bbd02b
commit 92bcd19925
11 changed files with 136 additions and 65 deletions

View file

@ -41,7 +41,7 @@ pub trait ArrangerTrackApi: Sized {
/// Identifying color of track
fn color (&self) -> ItemColor;
/// The MIDI player for the track
fn player (&self) -> MIDIPlayer;
fn player (&self) -> &impl PlayerApi;
fn longest_name (tracks: &[Self]) -> usize {
tracks.iter().map(|s|s.name().read().unwrap().len()).fold(0, usize::max)