Make UniformList non-occluding. (#9806)
Fixes https://github.com/zed-industries/zed/issues/9723 Move the `occlude` in the places where they are needed. Release Notes: - Fixed right click in the project panel's empty region ([9723](https://github.com/zed-industries/zed/issues/9723)) Co-authored-by: Antonio Scandurra <antonio@zed.dev>
This commit is contained in:
parent
db9221aa57
commit
b8663e56a9
2 changed files with 3 additions and 4 deletions
|
@ -898,9 +898,7 @@ impl CompletionsMenu {
|
||||||
.max_w(px(640.))
|
.max_w(px(640.))
|
||||||
.w(px(500.))
|
.w(px(500.))
|
||||||
.overflow_y_scroll()
|
.overflow_y_scroll()
|
||||||
// Prevent a mouse down on documentation from being propagated to the editor,
|
.occlude()
|
||||||
// because that would move the cursor.
|
|
||||||
.on_mouse_down(MouseButton::Left, |_, cx| cx.stop_propagation())
|
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
None
|
None
|
||||||
|
@ -989,6 +987,7 @@ impl CompletionsMenu {
|
||||||
.collect()
|
.collect()
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
.occlude()
|
||||||
.max_h(max_height)
|
.max_h(max_height)
|
||||||
.track_scroll(self.scroll_handle.clone())
|
.track_scroll(self.scroll_handle.clone())
|
||||||
.with_width_from_item(widest_completion_ix);
|
.with_width_from_item(widest_completion_ix);
|
||||||
|
@ -1212,6 +1211,7 @@ impl CodeActionsMenu {
|
||||||
.px_2()
|
.px_2()
|
||||||
.py_1()
|
.py_1()
|
||||||
.max_h(max_height)
|
.max_h(max_height)
|
||||||
|
.occlude()
|
||||||
.track_scroll(self.scroll_handle.clone())
|
.track_scroll(self.scroll_handle.clone())
|
||||||
.with_width_from_item(
|
.with_width_from_item(
|
||||||
self.actions
|
self.actions
|
||||||
|
|
|
@ -48,7 +48,6 @@ where
|
||||||
interactivity: Interactivity {
|
interactivity: Interactivity {
|
||||||
element_id: Some(id),
|
element_id: Some(id),
|
||||||
base_style: Box::new(base_style),
|
base_style: Box::new(base_style),
|
||||||
occlude_mouse: true,
|
|
||||||
|
|
||||||
#[cfg(debug_assertions)]
|
#[cfg(debug_assertions)]
|
||||||
location: Some(*core::panic::Location::caller()),
|
location: Some(*core::panic::Location::caller()),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue