Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Revert "Invalidate tooltips when mouse leaves element's hitbox (#22488)" (#22542)
Kirill Bulatov38938ece4986
diff --git a/crates/gpui/src/elements/div.rs b/crates/gpui/src/elements/div.rsindex c4143a13caa..36f42c137c1 100644--- a/crates/gpui/src/elements/div.rs+++ b/crates/gpui/src/elements/div.rs@@ -1417,19 +1417,6 @@ impl Interactivity {None};- let invalidate_tooltip = hitbox- .as_ref()- .map_or(true, |hitbox| !hitbox.bounds.contains(&cx.mouse_position()));- if invalidate_tooltip {- if let Some(active_tooltip) = element_state- .as_ref()- .and_then(|state| state.active_tooltip.as_ref())- {- *active_tooltip.borrow_mut() = None;- self.tooltip_id = None;- }- }-let scroll_offset = self.clamp_scroll_position(bounds, &style, cx);let result = f(&style, scroll_offset, hitbox, cx);(result, element_state)