mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-19 07:22:21 +00:00
LibWeb: Adjust positions by the scroll offset for scrollbar hit testing
This ensures we scroll to the correct position when dragging a scrollbar or clicking its gutter.
This commit is contained in:
parent
22532c769c
commit
c846616d51
Notes:
github-actions[bot]
2025-05-08 09:41:59 +00:00
Author: https://github.com/trflynn89
Commit: c846616d51
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4640
Reviewed-by: https://github.com/AtkinsSJ ✅
2 changed files with 12 additions and 2 deletions
|
@ -274,6 +274,7 @@ protected:
|
|||
[[nodiscard]] bool could_be_scrolled_by_wheel_event(ScrollDirection) const;
|
||||
|
||||
TraversalDecision hit_test_scrollbars(CSSPixelPoint position, Function<TraversalDecision(HitTestResult)> const& callback) const;
|
||||
CSSPixelPoint adjust_position_for_cumulative_scroll_offset(CSSPixelPoint) const;
|
||||
|
||||
private:
|
||||
[[nodiscard]] virtual bool is_paintable_box() const final { return true; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue