mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-07 12:16:42 +01:00
wip: ArrangerStandalone
This commit is contained in:
parent
1104093395
commit
3cbb2d2e0b
19 changed files with 165 additions and 231 deletions
|
|
@ -25,7 +25,7 @@ pub fn handle_mixer (state: &mut Mixer, event: &AppEvent) -> Usually<bool> {
|
|||
if state.selected_track == 0 {
|
||||
state.selected_track = state.tracks.len() - 1;
|
||||
} else {
|
||||
state.selected_track = state.selected_track - 1;
|
||||
state.selected_track -= 1;
|
||||
}
|
||||
println!("{}", state.selected_track);
|
||||
return Ok(true)
|
||||
|
|
@ -34,7 +34,7 @@ pub fn handle_mixer (state: &mut Mixer, event: &AppEvent) -> Usually<bool> {
|
|||
if state.selected_column == 0 {
|
||||
state.selected_column = 6
|
||||
} else {
|
||||
state.selected_column = state.selected_column - 1;
|
||||
state.selected_column -= 1;
|
||||
}
|
||||
return Ok(true)
|
||||
},
|
||||
|
|
@ -42,7 +42,7 @@ pub fn handle_mixer (state: &mut Mixer, event: &AppEvent) -> Usually<bool> {
|
|||
if state.selected_column == 6 {
|
||||
state.selected_column = 0
|
||||
} else {
|
||||
state.selected_column = state.selected_column + 1;
|
||||
state.selected_column += 1;
|
||||
}
|
||||
return Ok(true)
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1,9 +1,5 @@
|
|||
use crate::*;
|
||||
use tek_core::edn;
|
||||
#[cfg(feature = "standalone_devices")]
|
||||
use tek_sampler::*;
|
||||
#[cfg(feature = "standalone_devices")]
|
||||
use tek_plugin::*;
|
||||
|
||||
/// A sequencer track.
|
||||
#[derive(Debug)]
|
||||
|
|
@ -74,9 +70,7 @@ impl Track {
|
|||
Edn::List(args) => match args.get(0) {
|
||||
// Add a sampler device to the track
|
||||
Some(Edn::Symbol(SYM_SAMPLER)) => {
|
||||
#[cfg(feature = "standalone_devices")]
|
||||
devices.push(Sampler::from_edn(&args[1..])?);
|
||||
#[cfg(not(feature = "standalone_devices"))]
|
||||
panic!(
|
||||
"unsupported in track {}: {:?}; tek_mixer not compiled with feature \"sampler\"",
|
||||
&track.name,
|
||||
|
|
@ -85,9 +79,7 @@ impl Track {
|
|||
},
|
||||
// Add a LV2 plugin to the track.
|
||||
Some(Edn::Symbol(SYM_LV2)) => {
|
||||
#[cfg(feature = "standalone_devices")]
|
||||
devices.push(LV2Plugin::from_edn(&args[1..])?);
|
||||
#[cfg(not(feature = "standalone_devices"))]
|
||||
panic!(
|
||||
"unsupported in track {}: {:?}; tek_mixer not compiled with feature \"plugin\"",
|
||||
&track.name,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue