-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Stop using -_canScrollWithoutBouncing(X|Y) and -_adjustedContentOffse…
…tForContentOffset: on UIScrollView https://bugs.webkit.org/show_bug.cgi?id=262973 Reviewed by Richard Robinson. Remove uses of these three SPI methods and properties on `UIScrollView`, which are currently just used for smooth keyboard scrolling on iOS: ``` -_canScrollWithoutBouncingX -_canScrollWithoutBouncingY -_adjustedContentOffsetForContentOffset: ``` Instead, we use a combination `-adjustedContentInset`, `-contentSize` and `-bounds` to both compute the scroll extents and total content dimensions of the content scroll view, and to adjust a given content offset to fit within the extents. * Source/WebKit/Platform/spi/ios/UIKitSPI.h: Remove the now-unnecessary SPI declarations. * Source/WebKit/UIProcess/ios/UIKitUtilities.h: * Source/WebKit/UIProcess/ios/UIKitUtilities.mm: (-[UIScrollView _wk_contentWidthIncludingInsets]): (-[UIScrollView _wk_contentHeightIncludingInsets]): (-[UIScrollView _wk_isScrolledBeyondExtents]): (-[UIScrollView _wk_clampToScrollExtents:]): (-[UIScrollView _wk_canScrollHorizontallyWithoutBouncing]): (-[UIScrollView _wk_canScrollVerticallyWithoutBouncing]): * Source/WebKit/UIProcess/ios/WKKeyboardScrollingAnimator.mm: (-[WKKeyboardScrollViewAnimator boundedContentOffset:]): (-[WKKeyboardScrollViewAnimator rubberbandableDirections]): * Source/WebKit/UIProcess/ios/WKVelocityTrackingScrollView.mm: Drive-by fix: remove an unnecessary header import for `FixedVector.h`. Canonical link: https://commits.webkit.org/269186@main
- Loading branch information
Showing
5 changed files
with
65 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters