[webkit-changes] [WebKit/WebKit] 478618: Clean up ScrollerPairMac, and fix a bug with RTL s...
Simon Fraser
noreply at github.com
Tue Mar 14 21:36:42 PDT 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 478618b3a4aa237f81272cd2cbe27426323d897e
https://github.com/WebKit/WebKit/commit/478618b3a4aa237f81272cd2cbe27426323d897e
Author: Simon Fraser <simon.fraser at apple.com>
Date: 2023-03-14 (Tue, 14 Mar 2023)
Changed paths:
M Source/WebCore/page/scrolling/mac/ScrollerMac.h
M Source/WebCore/page/scrolling/mac/ScrollerMac.mm
M Source/WebCore/page/scrolling/mac/ScrollerPairMac.h
M Source/WebCore/page/scrolling/mac/ScrollerPairMac.mm
M Source/WebCore/page/scrolling/mac/ScrollingTreeScrollingNodeDelegateMac.mm
M Source/WebCore/platform/ScrollableArea.cpp
M Source/WebCore/platform/ScrollableArea.h
Log Message:
-----------
Clean up ScrollerPairMac, and fix a bug with RTL scrollbars
https://bugs.webkit.org/show_bug.cgi?id=253871
rdar://106682101
Reviewed by Aditya Keerthi.
A future patch may need to add locking around code that touches NSScrollerImp*, so it's helpful
if the NSScrollerImp* are hidden inside ScrollerPairMac/ScrollerMac, so do that.
Also do some other cleanup:
1. Replace ScrollerMac::Orientation with the existing ScrollbarOrientation enum
2. Move the calls to -setUsePresentationValue: and setPresentationValue: inside ScrollerPairMac
3. Have ScrollingTreeScrollingNodeDelegateMac::updateScrollbarPainters() use ScrollerPairMac::valuesForOrientation()
and fix that code to use scroll offsets instead of positions, which fixes a bug where RTL scrollbars would sometimes
flicker to the wrong positions.
4. Rename the 'doubleValue' param to ScrollableArea::computeScrollbarValueAndOverhang() to scrollbarValue.
Canonical link: https://commits.webkit.org/261673@main
More information about the webkit-changes
mailing list