mirror of
https://github.com/zed-industries/zed.git
synced 2024-11-08 07:35:01 +03:00
Dismiss outline view when the query editor is blurred
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
parent
b52db22544
commit
e4c0fc6ad5
@ -224,6 +224,4 @@ impl View for GoToLine {
|
||||
fn on_focus(&mut self, cx: &mut ViewContext<Self>) {
|
||||
cx.focus(&self.line_editor);
|
||||
}
|
||||
|
||||
fn on_blur(&mut self, _: &mut ViewContext<Self>) {}
|
||||
}
|
||||
|
@ -258,6 +258,7 @@ impl OutlineView {
|
||||
cx: &mut ViewContext<Self>,
|
||||
) {
|
||||
match event {
|
||||
editor::Event::Blurred => cx.emit(Event::Dismissed),
|
||||
editor::Event::Edited => self.update_matches(cx),
|
||||
_ => {}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user