From 08402e25e0cf0cdc3c8a6fd487aebe501274204f Mon Sep 17 00:00:00 2001 From: Finn Evers Date: Sat, 26 Jul 2025 17:45:13 +0200 Subject: [PATCH] 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 --- crates/ui/src/components/scrollbar.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/ui/src/components/scrollbar.rs b/crates/ui/src/components/scrollbar.rs index 6a64659f24306f01498603768cb2f6deebf5b273..7af55b76b71caf7b49c742365068886b44685124 100644 --- a/crates/ui/src/components/scrollbar.rs +++ b/crates/ui/src/components/scrollbar.rs @@ -339,7 +339,7 @@ impl Element for Scrollbar { move |event: &MouseDownEvent, phase, _, _| { if !phase.bubble() || event.button != MouseButton::Left - || bounds.contains(&event.position) + || !bounds.contains(&event.position) { return; }