Bug 197117

Summary: Add more _WKElementActionTypes and provide API to create with custom types
Product: WebKit Reporter: Dean Jackson <dino>
Component: New BugsAssignee: Dean Jackson <dino>
Status: RESOLVED FIXED    
Severity: Normal CC: thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch thorton: review+

Description Dean Jackson 2019-04-19 14:28:09 PDT
Add more _WKElementActionTypes and provide API to create with custom types
Comment 1 Radar WebKit Bug Importer 2019-04-19 14:28:36 PDT
<rdar://problem/50059548>
Comment 2 Dean Jackson 2019-04-19 14:34:10 PDT
Created attachment 367828 [details]
Patch
Comment 3 Dean Jackson 2019-04-19 14:42:42 PDT
Created attachment 367831 [details]
Patch
Comment 4 Tim Horton 2019-04-19 14:44:16 PDT
Comment on attachment 367831 [details]
Patch

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

> Source/WebKit/UIProcess/API/Cocoa/_WKElementAction.h:45
> +    _WKElementActionTypeShare WK_API_AVAILABLE(macos(WK_MAC_TBA), ios(10.0)),

This one shouldn't be TBA

> Source/WebKit/UIProcess/API/Cocoa/_WKElementAction.h:55
> -+ (instancetype)elementActionWithType:(_WKElementActionType)type customTitle:(NSString *)title;
> ++ (instancetype)elementActionWithType:(_WKElementActionType)type title:(NSString *)title actionHandler:(WKElementActionHandler)actionHandler;

Are you sure there are no clients of the old SPI‽ Also, this needs availability.
Comment 5 Dean Jackson 2019-04-19 14:57:41 PDT
Created attachment 367835 [details]
Patch
Comment 6 Dean Jackson 2019-04-19 15:25:10 PDT
Committed r244472: <https://trac.webkit.org/changeset/244472>