WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
195222
Drop legacy userAgentForURL injected bundle SPI
https://bugs.webkit.org/show_bug.cgi?id=195222
Summary
Drop legacy userAgentForURL injected bundle SPI
Chris Dumez
Reported
2019-03-01 12:46:56 PST
Deprecate userAgentForURL injected bundle SPI. There are no longer any clients, using WebsitePolicies.customUserAgent is the way to go nowadays.
Attachments
Patch
(11.34 KB, patch)
2019-03-01 12:48 PST
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(12.53 KB, patch)
2019-03-04 11:52 PST
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(12.58 KB, patch)
2019-03-04 11:58 PST
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2019-03-01 12:47:37 PST
<
rdar://problem/46734147
>
Chris Dumez
Comment 2
2019-03-01 12:48:29 PST
Created
attachment 363361
[details]
Patch
Darin Adler
Comment 3
2019-03-01 22:25:52 PST
Comment on
attachment 363361
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=363361&action=review
> Source/WebKit/ChangeLog:3 > + Deprecate userAgentForURL injected bundle SPI
This does more than just deprecate it. It also removes support for it, in other words makes it not be called any more. That’s not what "deprecate" means. So this is more like "remove support for" rather than "deprecate".
> Source/WebKit/WebProcess/InjectedBundle/API/Cocoa/WKWebProcessPlugInLoadDelegate.h:67 > +- (NSString *)webProcessPlugInBrowserContextController:(WKWebProcessPlugInBrowserContextController *)controller frame:(WKWebProcessPlugInFrame *)frame userAgentForURL:(NSURL *)url WK_API_DEPRECATED("Use _WKWebsitePolicies.customUserAgent instead", macosx(WK_MAC_TBA, WK_MAC_TBA), ios(WK_IOS_TBA, WK_IOS_TBA));
Why are we leaving this in the header at all? This is not API, so what benefit is there for this being here and marked deprecated rather than removed? These deprecation macros have helpful behavior for methods that might be called. I’m not sure they do any good for optional methods in a protocol that are are meant to be implemented. I suggest just deleting this line unless I am missing something.
> Source/WebKit/WebProcess/WebPage/WebPage.cpp:3169 > +String WebPage::userAgent(WebFrame*, const URL& webcoreURL) const
Should we change this to not even take a WebFrame pointer and update callers to no longer pass it?
Chris Dumez
Comment 4
2019-03-04 11:52:29 PST
Created
attachment 363533
[details]
Patch
Chris Dumez
Comment 5
2019-03-04 11:58:38 PST
Created
attachment 363536
[details]
Patch
WebKit Commit Bot
Comment 6
2019-03-04 12:36:38 PST
Comment on
attachment 363536
[details]
Patch Clearing flags on attachment: 363536 Committed
r242375
: <
https://trac.webkit.org/changeset/242375
>
WebKit Commit Bot
Comment 7
2019-03-04 12:36:40 PST
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug