mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-28 20:01:33 +00:00
Dismiss dropdowns on click out
This commit is contained in:
parent
525521eeb3
commit
026ad191eb
1 changed files with 10 additions and 2 deletions
|
@ -385,7 +385,11 @@ impl CollabTitlebarItem {
|
|||
.with_height(theme.contacts_popover.height)
|
||||
})
|
||||
.on_click(MouseButton::Left, |_, _, _| {})
|
||||
.on_down_out(MouseButton::Left, move |_, _, cx| cx.emit(()))
|
||||
.on_down_out(MouseButton::Left, move |_, this, cx| {
|
||||
this.branch_popover.take();
|
||||
cx.emit(());
|
||||
cx.notify();
|
||||
})
|
||||
.into_any();
|
||||
|
||||
Overlay::new(child)
|
||||
|
@ -415,7 +419,11 @@ impl CollabTitlebarItem {
|
|||
.with_height(theme.contacts_popover.height)
|
||||
})
|
||||
.on_click(MouseButton::Left, |_, _, _| {})
|
||||
.on_down_out(MouseButton::Left, move |_, _, cx| cx.emit(()))
|
||||
.on_down_out(MouseButton::Left, move |_, this, cx| {
|
||||
this.project_popover.take();
|
||||
cx.emit(());
|
||||
cx.notify();
|
||||
})
|
||||
.into_any();
|
||||
|
||||
Overlay::new(child)
|
||||
|
|
Loading…
Reference in a new issue