more updates to space and transport

This commit is contained in:
🪞👃🪞 2024-12-30 14:31:00 +01:00
parent 9fa858f226
commit 304ce35cbb
6 changed files with 139 additions and 140 deletions

View file

@ -117,15 +117,16 @@ render!(<Tui>|self:Groovebox|{
let pool_w = if self.pool.visible { phrase_w } else { 0 };
let sampler_w = 11;
let note_pt = self.editor.note_point();
let color = self.player.play_phrase().as_ref()
.and_then(|(_,p)|p.as_ref().map(|p|p.read().unwrap().color))
.clone();
Fill::wh(lay!([
&self.size,
Fill::wh(Align::s(Fixed::h(2, GrooveboxStatus::from(self)))),
Shrink::y(2, col!([
Fixed::h(2, row!([
Fixed::wh(5, 2, PlayPause(self.clock().is_rolling())),
Fixed::h(2, TransportView::from((self, self.player.play_phrase().as_ref().map(|(_,p)|
p.as_ref().map(|p|p.read().unwrap().color)
).flatten().clone(), true))),
Fixed::h(3, row!([
PlayPause(self.clock().is_rolling()),
TransportView::new(self, color, true),
])),
Push::x(sampler_w, Fixed::h(1, row!([
PhraseSelector::play_phrase(&self.player),