mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-08 12:46:42 +01:00
wip(p64,e4)
This commit is contained in:
parent
f49823b7a7
commit
fffd830e15
11 changed files with 194 additions and 217 deletions
|
|
@ -6,10 +6,9 @@ pub struct PhrasesView<'a, T: PhrasesViewState>(pub &'a T);
|
|||
|
||||
pub struct PhraseView<'a, T: PhraseViewState>(pub &'a T);
|
||||
|
||||
pub trait TransportViewState: ClockApi + PlayheadApi + Send + Sync {
|
||||
pub trait TransportViewState: ClockApi + Send + Sync {
|
||||
fn transport_selected (&self) -> TransportFocus;
|
||||
fn transport_focused (&self) -> bool;
|
||||
fn transport_state (&self) -> Option<TransportState>;
|
||||
fn bpm_value (&self) -> f64 {
|
||||
self.bpm().get()
|
||||
}
|
||||
|
|
@ -57,9 +56,6 @@ impl TransportViewState for TransportTui {
|
|||
fn transport_focused (&self) -> bool {
|
||||
true
|
||||
}
|
||||
fn transport_state (&self) -> Option<TransportState> {
|
||||
*self.playing().read().unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
impl TransportViewState for SequencerTui {
|
||||
|
|
@ -69,9 +65,6 @@ impl TransportViewState for SequencerTui {
|
|||
fn transport_focused (&self) -> bool {
|
||||
self.focused() == SequencerFocus::Transport
|
||||
}
|
||||
fn transport_state (&self) -> Option<TransportState> {
|
||||
*self.playing().read().unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
impl TransportViewState for ArrangerTui {
|
||||
|
|
@ -81,9 +74,6 @@ impl TransportViewState for ArrangerTui {
|
|||
fn transport_focused (&self) -> bool {
|
||||
self.focused() == ArrangerFocus::Transport
|
||||
}
|
||||
fn transport_state (&self) -> Option<TransportState> {
|
||||
*self.playing().read().unwrap()
|
||||
}
|
||||
}
|
||||
|
||||
impl ArrangerViewState for ArrangerTui {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue