Introduce SPI to request modern compatibility mode but defer to site-specific quirks
authorwenson_hsieh@apple.com <wenson_hsieh@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 6 May 2019 17:50:25 +0000 (17:50 +0000)
committerwenson_hsieh@apple.com <wenson_hsieh@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 6 May 2019 17:50:25 +0000 (17:50 +0000)
commit94424edab7de5608842d18e02b4d580329005159
tree07547d14949a6604d9636aa068fb1cec8dbebec2
parent3ebdf6df91c4038d479e78309325c7a413d72763
Introduce SPI to request modern compatibility mode but defer to site-specific quirks
https://bugs.webkit.org/show_bug.cgi?id=197614
<rdar://problem/50208577>

Reviewed by Tim Horton.

Add plumbing for a new _allowSiteSpecificQuirksToOverrideCompatibilityMode SPI property on
WKWebpagePreferences.

* UIProcess/API/APIWebsitePolicies.cpp:
(API::WebsitePolicies::copy const):
* UIProcess/API/APIWebsitePolicies.h:
* UIProcess/API/Cocoa/WKWebpagePreferences.mm:
(-[WKWebpagePreferences _allowSiteSpecificQuirksToOverrideCompatibilityMode]):
(-[WKWebpagePreferences _setAllowSiteSpecificQuirksToOverrideCompatibilityMode:]):
* UIProcess/API/Cocoa/WKWebpagePreferencesPrivate.h:
* UIProcess/WebPageProxy.cpp:

Use currentRequest instead of originalRequest; see internal change for more details.

(WebKit::WebPageProxy::decidePolicyForNavigationAction):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@244966 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit/ChangeLog
Source/WebKit/UIProcess/API/APIWebsitePolicies.cpp
Source/WebKit/UIProcess/API/APIWebsitePolicies.h
Source/WebKit/UIProcess/API/Cocoa/WKWebpagePreferences.mm
Source/WebKit/UIProcess/API/Cocoa/WKWebpagePreferencesPrivate.h
Source/WebKit/UIProcess/WebPageProxy.cpp