mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-09 13:16:44 +01:00
nice top level command dispatch
This commit is contained in:
parent
aad7aa6c5e
commit
8dcf73c18c
8 changed files with 137 additions and 144 deletions
|
|
@ -152,11 +152,6 @@ pub enum MidiEditCommand {
|
|||
SetTimeLock(bool),
|
||||
Show(Option<Arc<RwLock<MidiClip>>>),
|
||||
}
|
||||
impl MidiEditCommand {
|
||||
pub fn from_edn <'a> (head: &EdnItem<&str>, tail: &'a [EdnItem<String>]) -> Self {
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
handle!(TuiIn: |self: MidiEditor, input|MidiEditCommand::execute_with_state(self, input.event()));
|
||||
keymap!(KEYS_MIDI_EDITOR = |s: MidiEditor, _input: Event| MidiEditCommand {
|
||||
key(Up) => SetNoteCursor(s.note_point() + 1),
|
||||
|
|
@ -217,3 +212,8 @@ impl Command<MidiEditor> for MidiEditCommand {
|
|||
Ok(None)
|
||||
}
|
||||
}
|
||||
impl EdnCommand<MidiEditor> for MidiEditCommand {
|
||||
fn from_edn <'a> (state: &MidiEditor, head: &EdnItem<&str>, tail: &'a [EdnItem<String>]) -> Self {
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue