arranger: open and close rename modal

This commit is contained in:
🪞👃🪞 2024-08-20 14:09:03 +03:00
parent b0f4919030
commit c8bdee060c
7 changed files with 92 additions and 17 deletions

View file

@ -20,6 +20,7 @@ pub struct Arranger {
pub transport: Option<Arc<RwLock<TransportToolbar>>>,
pub show_sequencer: Option<Direction>,
pub focus_sequencer: bool,
pub modal: Option<Box<dyn ExitableComponent>>,
}
impl Arranger {
@ -35,6 +36,7 @@ impl Arranger {
transport: None,
show_sequencer: Some(Direction::Down),
focus_sequencer: false,
modal: None
}
}
pub fn activate (&mut self) {
@ -145,4 +147,7 @@ impl Arranger {
pub fn scene_default_name (&self) -> String {
format!("Scene {}", self.scenes.len() + 1)
}
pub fn rename_selected (&mut self) {
self.modal = Some(Box::new(ArrangerRenameModal::new(self.selected)));
}
}