diff --git a/crates/ui/src/components/scrollbar.rs b/crates/ui/src/components/scrollbar.rs index d85ef8f506df59a60ca571307516eadb4030aaa2..bfcaa93eb41f22c36d106273f6da98da38981f62 100644 --- a/crates/ui/src/components/scrollbar.rs +++ b/crates/ui/src/components/scrollbar.rs @@ -1102,7 +1102,6 @@ impl Element for ScrollbarElement { .disabled() .not() .then(|| ScrollbarPrepaintState { - parent_bounds_hitbox: window.insert_hitbox(bounds, HitboxBehavior::Normal), thumbs: { let thumb_ranges = self.state.read(cx).thumb_ranges().collect::>(); let width = self.state.read(cx).width.to_pixels(); @@ -1178,6 +1177,7 @@ impl Element for ScrollbarElement { }) .collect() }, + parent_bounds_hitbox: window.insert_hitbox(bounds, HitboxBehavior::Normal), }); if prepaint_state .as_ref()