[webkit-changes] [WebKit/WebKit] d53ab7: Fix the iOS build after rdar://115866097
Wenson Hsieh
noreply at github.com
Tue Sep 3 20:47:15 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: d53ab7c16664e076925dd62f6a03e5074067d63e
https://github.com/WebKit/WebKit/commit/d53ab7c16664e076925dd62f6a03e5074067d63e
Author: Wenson Hsieh <wenson_hsieh at apple.com>
Date: 2024-09-03 (Tue, 03 Sep 2024)
Changed paths:
M Source/WebKit/UIProcess/ios/DragDropInteractionState.h
M Source/WebKit/UIProcess/ios/DragDropInteractionState.mm
M Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
M Tools/TestRunnerShared/spi/UIKitSPIForTesting.h
M Tools/TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm
M Tools/TestWebKitAPI/cocoa/DragAndDropSimulator.h
M Tools/TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm
Log Message:
-----------
Fix the iOS build after rdar://115866097
https://bugs.webkit.org/show_bug.cgi?id=279090
rdar://135224537
Reviewed by Abrar Rahman Protyasha.
Fix the iOS build, after the removal of the `UIDragInteractionDelegate_ForWebKitOnly` SPI protocol.
This was used to implement asynchronously-triggered drag interactions prior to iOS 17.4; however, on
iOS 17.4 and later, WebKit now uses public API from BrowserEngineKit's `BEDragInteractionDelegate`,
which offers parity with the SPI protocol.
The implementations of `BEDragInteractionDelegate` protocol methods currently wrap implementations
of their SPI counterparts. This was only done to make it possible to easily switch between using the
API and SPI with a runtime flag, while maintining binary and source compatibility with both. This is
no longer necessary since the oldest maintained version of WebKit is now iOS 17.5 (currently in EWS)
which uses the newer BrowserEngineKit APIs, so we can switch entirely to this new API.
* Source/WebKit/UIProcess/ios/DragDropInteractionState.h:
(WebKit::DragDropInteractionState::BlockPtr<BOOL):
(WebKit::DragDropInteractionState::BlockPtr<void): Deleted.
* Source/WebKit/UIProcess/ios/DragDropInteractionState.mm:
(WebKit::DragDropInteractionState::prepareForDragSession):
(WebKit::DragDropInteractionState::dragSessionWillRequestAdditionalItem):
* Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _didHandleDragStartRequest:]):
(-[WKContentView dragInteraction:prepareDragSession:completion:]):
(-[WKContentView dragInteraction:itemsForAddingToSession:forTouchAtPoint:completion:]):
(-[WKContentView _dragInteraction:itemsForAddingToSession:withTouchAtPoint:completion:]): Deleted.
(-[WKContentView _dragInteraction:prepareForSession:completion:]): Deleted.
* Tools/TestRunnerShared/spi/UIKitSPIForTesting.h:
* Tools/TestWebKitAPI/Tests/ios/DragAndDropTestsIOS.mm:
(TestWebKitAPI::TEST(DragAndDropTests, UnresponsivePageDoesNotHangUI)):
* Tools/TestWebKitAPI/cocoa/DragAndDropSimulator.h:
* Tools/TestWebKitAPI/ios/DragAndDropSimulatorIOS.mm:
(-[WKWebView dropInteractionDelegate]):
(-[WKWebView dragInteractionDelegate]):
(-[DragAndDropSimulator runFrom:to:additionalItemRequestLocations:]):
(-[DragAndDropSimulator _sendQueuedAdditionalItemRequest]):
Teach the drag and drop test harness to start simulated drag sessions by calling into
`BEDragInteractionDelegate` APIs, rather than the legacy UIKit SPI.
Canonical link: https://commits.webkit.org/283132@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list