Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Match zed1 scrollbar drag behavior
Julia51396344a3f5
diff --git a/crates/editor2/src/element.rs b/crates/editor2/src/element.rsindex cf34863ba6d..0c9d0b46a89 100644--- a/crates/editor2/src/element.rs+++ b/crates/editor2/src/element.rs@@ -1369,7 +1369,7 @@ impl EditorElement {{let y = mouse_position.y;let new_y = event.position.y;- if thumb_top < y && y < thumb_bottom {+ if (track_bounds.top()..track_bounds.bottom()).contains(&y) {let mut position = editor.scroll_position(cx);position.y += (new_y - y) * (max_row as f32) / height;if position.y < 0.0 {