Bug 227603

Summary: Provide SPI for clients to override just the contextmenu preview instead of the entire `UIContextMenuConfiguration`
Product: WebKit Reporter: Devin Rousso <drousso>
Component: New BugsAssignee: Devin Rousso <drousso>
Status: RESOLVED FIXED    
Severity: Normal CC: drousso, thorton, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch none

Description Devin Rousso 2021-07-01 17:11:32 PDT
.
Comment 1 Devin Rousso 2021-07-01 17:11:51 PDT
<rdar://problem/78832586>
Comment 2 Devin Rousso 2021-07-01 17:16:19 PDT
Created attachment 432753 [details]
Patch
Comment 3 Wenson Hsieh 2021-07-01 17:39:13 PDT
Comment on attachment 432753 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=432753&action=review

> Source/WebKit/UIProcess/API/Cocoa/WKUIDelegatePrivate.h:185
> +- (UIViewController *)_webView:(WKWebView *)webView contextMenuPreviewForElement:(WKContextMenuElementInfo *)elementInfo WK_API_AVAILABLE(ios(WK_IOS_TBA));

I'd maybe call this `-_webView:contextMenuContentPreviewForElement:` to match the wording in `UIContextMenuContentPreviewProvider`.

Since this is going into iOS 15 and we've already replaced all the TBA macros for iOS 15/macOS 12, I think we should also make this `ios(15.0)` from the start.
Comment 4 Devin Rousso 2021-07-06 12:13:27 PDT
Created attachment 432959 [details]
Patch
Comment 5 EWS 2021-07-06 15:34:51 PDT
Committed r279625 (239443@main): <https://commits.webkit.org/239443@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 432959 [details].