reorder panes, start in sequencer

This commit is contained in:
🪞👃🪞 2024-05-29 14:18:05 +03:00
parent b6c093b355
commit 265dc13248
2 changed files with 48 additions and 28 deletions

View file

@ -6,19 +6,31 @@ pub use self::jack::*;
pub use self::render::*;
use crate::prelude::*;
pub const ACTIONS: [(&'static str, &'static str);2] = [
("(Shift-)Tab, Arrows ", "Navigate"),
//("Home", "⏹ Stop and rewind"),
("(Shift-)Space", " Play/pause"),
pub const ACTIONS: [(&'static str, &'static str);3] = [
("(Shift-)Tab", "Switch pane"),
("Arrows", "Navigate"),
("(Shift-)Space", " Play/pause"),
];
pub struct Transport {
exited: bool
exited: bool,
sample_rate: u64,
position: u64,
bpm: f64,
}
impl Transport {
pub fn new () -> Result<Self, Box<dyn Error>> {
Ok(Self { exited: false })
Ok(Self {
exited: false,
sample_rate: 48000,
position: 0,
bpm: 120.0
})
}
pub fn play_from_start_or_stop_and_rewind (&mut self) {
}
pub fn play_or_pause (&mut self) {
}
}