mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-30 04:39:06 +00:00
LibWeb: Extract hit testing on children into a separate method
This way we can reuse the logic between PaintableWithLines and PaintableBox. It also introduces the .is_positioned() check for the children of a PaintableWithLines, which makes sure to skip positioned child nodes since those are handled by the StackingContext.
This commit is contained in:
parent
e3864f9a9e
commit
c24be6a39d
Notes:
github-actions[bot]
2025-07-05 22:57:52 +00:00
Author: https://github.com/gmta
Commit: c24be6a39d
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/5298
Reviewed-by: https://github.com/tcl3 ✅
2 changed files with 16 additions and 11 deletions
|
@ -147,6 +147,7 @@ public:
|
|||
|
||||
[[nodiscard]] virtual TraversalDecision hit_test(CSSPixelPoint position, HitTestType type, Function<TraversalDecision(HitTestResult)> const& callback) const override;
|
||||
Optional<HitTestResult> hit_test(CSSPixelPoint, HitTestType) const;
|
||||
[[nodiscard]] TraversalDecision hit_test_children(CSSPixelPoint, HitTestType, Function<TraversalDecision(HitTestResult)> const&) const;
|
||||
[[nodiscard]] TraversalDecision hit_test_continuation(Function<TraversalDecision(HitTestResult)> const& callback) const;
|
||||
|
||||
virtual bool handle_mousewheel(Badge<EventHandler>, CSSPixelPoint, unsigned buttons, unsigned modifiers, int wheel_delta_x, int wheel_delta_y) override;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue