Overhaul UI event handling

This commit is contained in:
Joscha 2022-08-20 18:36:20 +02:00
parent ade06efa01
commit ded927b9f0
9 changed files with 177 additions and 103 deletions

View file

@ -90,7 +90,7 @@ impl<M: Msg, S: MsgStore<M>> ChatState<M, S> {
}
}
pub async fn handle_event(
pub async fn handle_input_event(
&mut self,
terminal: &mut Terminal,
crossterm_lock: &Arc<FairMutex<()>>,
@ -100,7 +100,7 @@ impl<M: Msg, S: MsgStore<M>> ChatState<M, S> {
match self.mode {
Mode::Tree => {
self.tree
.handle_event(terminal, crossterm_lock, event, can_compose)
.handle_input_event(terminal, crossterm_lock, event, can_compose)
.await
}
}