Add modern WebKit SPI to set the auto fill button type and query whether the auto fill button is enabled. Specifically, add SPI equivalents for WKBundleNodeHandleGetHTMLInputElementAutoFillButtonEnabled() and WKBundleNodeHandleSetHTMLInputElementAutoFillButtonEnabledWithButtonType().
Created attachment 329061 [details] Patch
<rdar://problem/35983093>
Comment on attachment 329061 [details] Patch C SPI exists for both of these. Is there an advantage to making ObjC equivalents?
(In reply to Alex Christensen from comment #3) > Comment on attachment 329061 [details] > Patch > > C SPI exists for both of these. Is there an advantage to making ObjC > equivalents? I thought the long term goal was to get rid of the C SPI.
(In reply to Alex Christensen from comment #3) > Comment on attachment 329061 [details] > Patch > > C SPI exists for both of these. Is there an advantage to making ObjC > equivalents? It would be great to have the ObjC SPI since in MobileSafari we only work with modern WebKit ObjC SPI, and even on macOS Safari we are trying to move away from the C APIs. There is already a node handle class in MobileSafari that fully expects an ObjC interface
Comment on attachment 329061 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=329061&action=review > Source/WebKit/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandlePrivate.h:30 > +typedef NS_ENUM(NSInteger, WKAutoFillButtonType) { Will prefix the name of this enumeration and its enumerators with an underscore before landing.
Comment on attachment 329061 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=329061&action=review >> Source/WebKit/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandlePrivate.h:30 >> +typedef NS_ENUM(NSInteger, WKAutoFillButtonType) { > > Will prefix the name of this enumeration and its enumerators with an underscore before landing. Will annotate this enumeration with WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA)) before landing. > Source/WebKit/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInNodeHandlePrivate.h:39 > +- (BOOL)isHTMLInputElementAutoFillButtonEnabled; > +- (void)setHTMLInputElementAutoFillButtonEnabledWithButtonType:(WKAutoFillButtonType)autoFillButtonType; Will annotate these with WK_API_AVAILABLE(macosx(WK_MAC_TBA), ios(WK_IOS_TBA)) before landing.
Committed r225833: <https://trac.webkit.org/changeset/225833>