ui: Fix scrollbar mouse down handler (#35131)
Follow-up to https://github.com/zed-industries/zed/pull/35121 - in the process of adding the check for the left mouse button to the guard (which was practically already there before, just not in the mouse-down listener), I accidentally removed the negation for the bounds check. This PR fixes this. Release Notes: - N/A
This commit is contained in:
@@ -339,7 +339,7 @@ impl Element for Scrollbar {
|
|||||||
move |event: &MouseDownEvent, phase, _, _| {
|
move |event: &MouseDownEvent, phase, _, _| {
|
||||||
if !phase.bubble()
|
if !phase.bubble()
|
||||||
|| event.button != MouseButton::Left
|
|| event.button != MouseButton::Left
|
||||||
|| bounds.contains(&event.position)
|
|| !bounds.contains(&event.position)
|
||||||
{
|
{
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user