Remove ViewContext::is_child

This commit is contained in:
Antonio Scandurra 2023-05-03 19:09:07 +02:00
parent 5157442703
commit 9e8f852afb
4 changed files with 42 additions and 75 deletions

View file

@ -134,6 +134,7 @@ pub enum Event {
RemoveItem { item_id: usize },
Split(SplitDirection),
ChangeItemTitle,
Focus,
}
pub struct Pane {
@ -1797,6 +1798,7 @@ impl View for Pane {
}
fn focus_in(&mut self, focused: AnyViewHandle, cx: &mut ViewContext<Self>) {
cx.emit(Event::Focus);
self.toolbar.update(cx, |toolbar, cx| {
toolbar.pane_focus_update(true, cx);
});