mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-24 18:28:57 +00:00
LibWeb: Use the soon-to-be hovered element for tooltip notifications
Instead of the currently hovered element.
This commit is contained in:
parent
a44e28fd56
commit
74722cc499
Notes:
github-actions[bot]
2025-08-06 16:27:30 +00:00
Author: https://github.com/awesomekling
Commit: 74722cc499
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5743
Reviewed-by: https://github.com/gmta ✅
1 changed files with 1 additions and 1 deletions
|
@ -848,7 +848,7 @@ EventResult EventHandler::handle_mousemove(CSSPixelPoint viewport_position, CSSP
|
|||
}
|
||||
|
||||
if (hovered_node_changed) {
|
||||
GC::Ptr<HTML::HTMLElement const> hovered_html_element = document.hovered_node() ? document.hovered_node()->enclosing_html_element_with_attribute(HTML::AttributeNames::title) : nullptr;
|
||||
GC::Ptr<HTML::HTMLElement const> hovered_html_element = node ? node->enclosing_html_element_with_attribute(HTML::AttributeNames::title) : nullptr;
|
||||
|
||||
if (hovered_html_element && hovered_html_element->title().has_value()) {
|
||||
page.set_is_in_tooltip_area(true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue