mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-07 04:06:45 +01:00
fix missing scene row (how?!)
This commit is contained in:
parent
ec81cbf2f1
commit
ee94df78f6
2 changed files with 6 additions and 8 deletions
|
|
@ -682,18 +682,15 @@ impl Scene {
|
|||
pub fn ppqs (scenes: &[Self], factor: usize) -> Vec<(usize, usize)> {
|
||||
let mut total = 0;
|
||||
if factor == 0 {
|
||||
let mut scenes: Vec<(usize, usize)> = scenes.iter().map(|scene|{
|
||||
scenes.iter().map(|scene|{
|
||||
let pulses = scene.pulses().max(PPQ);
|
||||
total = total + pulses;
|
||||
(pulses, total - pulses)
|
||||
}).collect();
|
||||
scenes.push((0, total));
|
||||
scenes
|
||||
}).collect()
|
||||
} else {
|
||||
let scenes: Vec<(usize, usize)> = (0..=scenes.len()).map(|i|{
|
||||
(0..=scenes.len()).map(|i|{
|
||||
(factor*PPQ, factor*PPQ*i)
|
||||
}).collect::<Vec<_>>();
|
||||
scenes
|
||||
}).collect()
|
||||
}
|
||||
}
|
||||
pub fn longest_name (scenes: &[Self]) -> usize {
|
||||
|
|
|
|||
|
|
@ -40,6 +40,7 @@ impl Content for ArrangerStatusBar {
|
|||
.bold(true);
|
||||
let commands = match self {
|
||||
Self::ArrangementMix => command(&[
|
||||
["", "c", "olor"],
|
||||
["", ",.", "scale rows"],
|
||||
["", "<>", "resize view"],
|
||||
]),
|
||||
|
|
@ -271,7 +272,7 @@ impl<'a> Content for VerticalArranger<'a, Tui> {
|
|||
}))?;
|
||||
|
||||
Ok(())
|
||||
}).bg(bg).border(border)
|
||||
}).bg(bg).grow_y(1).border(border)
|
||||
}
|
||||
}
|
||||
impl<'a> Content for HorizontalArranger<'a, Tui> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue