mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-09 05:06:43 +01:00
arranger: almost look like somethin now
This commit is contained in:
parent
ef6aa9ab07
commit
701ea3fc27
5 changed files with 97 additions and 76 deletions
|
|
@ -64,11 +64,6 @@ impl Arrangement {
|
|||
pub fn w_sidebar (&self, is_editing: bool) -> u16 {
|
||||
self.w() / if is_editing { 16 } else { 8 } as u16
|
||||
}
|
||||
/// Width taken by all tracks.
|
||||
pub fn w_tracks (&self) -> u16 {
|
||||
self.tracks_with_sizes(&self.selection(), None).last()
|
||||
.map(|(_, _, _, x)|x as u16).unwrap_or(0)
|
||||
}
|
||||
/// Width available to display tracks.
|
||||
pub fn w_tracks_area (&self, is_editing: bool) -> u16 {
|
||||
self.w().saturating_sub(self.w_sidebar(is_editing))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue