[webkit-changes] [WebKit/WebKit] 196398: [iOS] [WK2] Adopt _UIAsyncDragInteraction and _UIA...
Wenson Hsieh
noreply at github.com
Tue Sep 26 12:51:02 PDT 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 196398d09011b84ec6081ec5fb5ff932c0de2622
https://github.com/WebKit/WebKit/commit/196398d09011b84ec6081ec5fb5ff932c0de2622
Author: Wenson Hsieh <wenson_hsieh at apple.com>
Date: 2023-09-26 (Tue, 26 Sep 2023)
Changed paths:
M Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml
M Source/WebKit/Platform/spi/ios/UIKitSPI.h
M Source/WebKit/UIProcess/ios/WKContentViewInteraction.h
M Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
Log Message:
-----------
[iOS] [WK2] Adopt _UIAsyncDragInteraction and _UIAsyncDragInteractionDelegate
https://bugs.webkit.org/show_bug.cgi?id=262006
rdar://114331777
Reviewed by Tim Horton.
As a part of cleaning up asynchronous `UIInteraction` integration in WebKit, adopt a new
`_UIAsyncDragInteraction` subclass that encapsulates the delegate methods for both (1) starting a
drag session asynchronously, and (2) adding items to an existing drag session asynchronously.
* Source/WTF/Scripts/Preferences/UnifiedWebPreferences.yaml:
Add a runtime feature flag as well, to guard adoption of these new async `UIInteraction`s in UIKit.
* Source/WebKit/Platform/spi/ios/UIKitSPI.h:
* Source/WebKit/UIProcess/ios/WKContentViewInteraction.h:
* Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _dragInteractionClass]):
Add a helper method to return the drag interaction class to instantiate, based on runtime and build-
time flags.
(-[WKContentView setUpDragAndDropInteractions]):
(-[WKContentView asyncDragInteraction:prepareDragSession:completion:]):
(-[WKContentView asyncDragInteraction:itemsForAddingToSession:withTouchAtPoint:completion:]):
Implement the new `_UIAsyncDragInteractionDelegate` methods here.
Canonical link: https://commits.webkit.org/268470@main
More information about the webkit-changes
mailing list