mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-07 12:16:42 +01:00
whew: all 3 mini-apps launch again
This commit is contained in:
parent
6f5c28f671
commit
95dd61811e
4 changed files with 11 additions and 11 deletions
|
|
@ -13,7 +13,7 @@ pub trait HasPhrase: ClockApi {
|
||||||
|
|
||||||
fn phrase (&self)
|
fn phrase (&self)
|
||||||
-> &Option<(Instant, Option<Arc<RwLock<Phrase>>>)>;
|
-> &Option<(Instant, Option<Arc<RwLock<Phrase>>>)>;
|
||||||
fn phrase_mut (&self)
|
fn phrase_mut (&mut self)
|
||||||
-> &mut Option<(Instant, Option<Arc<RwLock<Phrase>>>)>;
|
-> &mut Option<(Instant, Option<Arc<RwLock<Phrase>>>)>;
|
||||||
|
|
||||||
fn next_phrase (&self)
|
fn next_phrase (&self)
|
||||||
|
|
|
||||||
|
|
@ -80,7 +80,7 @@ impl Content for ArrangerTui {
|
||||||
type Engine = Tui;
|
type Engine = Tui;
|
||||||
fn content (&self) -> impl Widget<Engine = Tui> {
|
fn content (&self) -> impl Widget<Engine = Tui> {
|
||||||
let arranger_focused = self.arranger_focused();
|
let arranger_focused = self.arranger_focused();
|
||||||
Split::up(
|
Split::down(
|
||||||
1,
|
1,
|
||||||
TransportView(self),
|
TransportView(self),
|
||||||
Split::down(
|
Split::down(
|
||||||
|
|
|
||||||
|
|
@ -58,16 +58,16 @@ macro_rules! impl_midi_player {
|
||||||
&mut self$(.$field)*.reset
|
&mut self$(.$field)*.reset
|
||||||
}
|
}
|
||||||
fn phrase (&self) -> &Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
fn phrase (&self) -> &Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
||||||
todo!("phrase")
|
&self$(.$field)*.play_phrase
|
||||||
}
|
}
|
||||||
fn phrase_mut (&self) -> &mut Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
fn phrase_mut (&mut self) -> &mut Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
||||||
todo!("phrase_mut")
|
&mut self$(.$field)*.play_phrase
|
||||||
}
|
}
|
||||||
fn next_phrase (&self) -> &Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
fn next_phrase (&self) -> &Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
||||||
todo!("next_phrase")
|
&self$(.$field)*.next_phrase
|
||||||
}
|
}
|
||||||
fn next_phrase_mut (&mut self) -> &mut Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
fn next_phrase_mut (&mut self) -> &mut Option<(Instant, Option<Arc<RwLock<Phrase>>>)> {
|
||||||
todo!("next_phrase_mut")
|
&mut self$(.$field)*.next_phrase
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
impl MidiInputApi for $Struct {
|
impl MidiInputApi for $Struct {
|
||||||
|
|
|
||||||
|
|
@ -64,7 +64,7 @@ impl ArrangerViewState for ArrangerTui {
|
||||||
pub trait PhrasesViewState: Send + Sync {
|
pub trait PhrasesViewState: Send + Sync {
|
||||||
fn phrases_focused (&self) -> bool;
|
fn phrases_focused (&self) -> bool;
|
||||||
fn phrases_entered (&self) -> bool;
|
fn phrases_entered (&self) -> bool;
|
||||||
fn phrases (&self) -> Vec<Arc<RwLock<Phrase>>>;
|
fn phrases (&self) -> &Vec<Arc<RwLock<Phrase>>>;
|
||||||
fn phrase_index (&self) -> usize;
|
fn phrase_index (&self) -> usize;
|
||||||
fn phrase_mode (&self) -> &Option<PhrasesMode>;
|
fn phrase_mode (&self) -> &Option<PhrasesMode>;
|
||||||
}
|
}
|
||||||
|
|
@ -77,11 +77,11 @@ macro_rules! impl_phrases_view_state {
|
||||||
fn phrases_entered (&$self2) -> bool {
|
fn phrases_entered (&$self2) -> bool {
|
||||||
$enter
|
$enter
|
||||||
}
|
}
|
||||||
fn phrases (&self) -> Vec<Arc<RwLock<Phrase>>> {
|
fn phrases (&self) -> &Vec<Arc<RwLock<Phrase>>> {
|
||||||
todo!()
|
&self$(.$field)*.phrases
|
||||||
}
|
}
|
||||||
fn phrase_index (&self) -> usize {
|
fn phrase_index (&self) -> usize {
|
||||||
todo!()
|
self$(.$field)*.phrase.load(Ordering::Relaxed)
|
||||||
}
|
}
|
||||||
fn phrase_mode (&self) -> &Option<PhrasesMode> {
|
fn phrase_mode (&self) -> &Option<PhrasesMode> {
|
||||||
&self$(.$field)*.mode
|
&self$(.$field)*.mode
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue