WebKit Bugzilla
Attachment 347549 Details for
Bug 188760
: Remove API::LoaderClient, which has been replaced by API::NavigationClient
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-188760-20180820153030.patch (text/plain), 54.66 KB, created by
Alex Christensen
on 2018-08-20 15:30:30 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Alex Christensen
Created:
2018-08-20 15:30:30 PDT
Size:
54.66 KB
patch
obsolete
>Index: Source/WebKit/ChangeLog >=================================================================== >--- Source/WebKit/ChangeLog (revision 235095) >+++ Source/WebKit/ChangeLog (working copy) >@@ -1,3 +1,60 @@ >+2018-08-20 Alex Christensen <achristensen@webkit.org> >+ >+ Remove API::LoaderClient, which has been replaced by API::NavigationClient >+ https://bugs.webkit.org/show_bug.cgi?id=188760 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UIProcess/API/APILoaderClient.h: Removed. >+ * UIProcess/API/C/WKPage.cpp: >+ (WKPageSetPageLoaderClient): >+ * UIProcess/WebPageProxy.cpp: >+ (WebKit::WebPageProxy::WebPageProxy): >+ (WebKit::WebPageProxy::close): >+ (WebKit::WebPageProxy::didChangeBackForwardList): >+ (WebKit::WebPageProxy::willGoToBackForwardListItem): >+ (WebKit::WebPageProxy::shouldKeepCurrentBackForwardListItemInList): >+ (WebKit::WebPageProxy::findPlugin): >+ (WebKit::WebPageProxy::didStartProgress): >+ (WebKit::WebPageProxy::didChangeProgress): >+ (WebKit::WebPageProxy::didFinishProgress): >+ (WebKit::WebPageProxy::didStartProvisionalLoadForFrame): >+ (WebKit::WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame): >+ (WebKit::WebPageProxy::didFailProvisionalLoadForFrame): >+ (WebKit::WebPageProxy::didCommitLoadForFrame): >+ (WebKit::WebPageProxy::didFinishDocumentLoadForFrame): >+ (WebKit::WebPageProxy::didFinishLoadForFrame): >+ (WebKit::WebPageProxy::didFailLoadForFrame): >+ (WebKit::WebPageProxy::didSameDocumentNavigationForFrame): >+ (WebKit::WebPageProxy::didReceiveTitleForFrame): >+ (WebKit::WebPageProxy::didFirstLayoutForFrame): >+ (WebKit::WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame): >+ (WebKit::WebPageProxy::didReachLayoutMilestone): >+ (WebKit::WebPageProxy::didDisplayInsecureContentForFrame): >+ (WebKit::WebPageProxy::didRunInsecureContentForFrame): >+ (WebKit::WebPageProxy::didDetectXSSForFrame): >+ (WebKit::WebPageProxy::didNavigateWithNavigationData): >+ (WebKit::WebPageProxy::didPerformClientRedirect): >+ (WebKit::WebPageProxy::didPerformServerRedirect): >+ (WebKit::WebPageProxy::didUpdateHistoryTitle): >+ (WebKit::WebPageProxy::webGLPolicyForURL): >+ (WebKit::WebPageProxy::resolveWebGLPolicyForURL): >+ (WebKit::WebPageProxy::processDidBecomeUnresponsive): >+ (WebKit::WebPageProxy::processDidBecomeResponsive): >+ (WebKit::WebPageProxy::dispatchProcessDidTerminate): >+ (WebKit::WebPageProxy::didReceiveAuthenticationChallengeProxy): >+ (WebKit::WebPageProxy::didFailToInitializePlugin): >+ (WebKit::WebPageProxy::didBlockInsecurePluginVersion): >+ (WebKit::WebPageProxy::navigationGestureDidBegin): >+ (WebKit::WebPageProxy::navigationGestureWillEnd): >+ (WebKit::WebPageProxy::navigationGestureDidEnd): >+ (WebKit::WebPageProxy::setLoaderClient): Deleted. >+ * UIProcess/WebPageProxy.h: >+ * UIProcess/ios/WebPageProxyIOS.mm: >+ (WebKit::WebPageProxy::didStartLoadForQuickLookDocumentInMainFrame): >+ (WebKit::WebPageProxy::didFinishLoadForQuickLookDocumentInMainFrame): >+ * WebKit.xcodeproj/project.pbxproj: >+ > 2018-08-20 Tim Horton <timothy_horton@apple.com> > > Fix the iOSMac build with unified sources >Index: Source/WebKit/UIProcess/WebPageProxy.cpp >=================================================================== >--- Source/WebKit/UIProcess/WebPageProxy.cpp (revision 235090) >+++ Source/WebKit/UIProcess/WebPageProxy.cpp (working copy) >@@ -40,7 +40,6 @@ > #include "APIHitTestResult.h" > #include "APIIconLoadingClient.h" > #include "APILegacyContextHistoryClient.h" >-#include "APILoaderClient.h" > #include "APINavigation.h" > #include "APINavigationAction.h" > #include "APINavigationClient.h" >@@ -378,7 +377,6 @@ Ref<WebPageProxy> WebPageProxy::create(P > WebPageProxy::WebPageProxy(PageClient& pageClient, WebProcessProxy& process, uint64_t pageID, Ref<API::PageConfiguration>&& configuration) > : m_pageClient(pageClient) > , m_configuration(WTFMove(configuration)) >- , m_loaderClient(std::make_unique<API::LoaderClient>()) > , m_policyClient(std::make_unique<API::PolicyClient>()) > , m_iconLoadingClient(std::make_unique<API::IconLoadingClient>()) > , m_formClient(std::make_unique<API::FormClient>()) >@@ -561,16 +559,6 @@ void WebPageProxy::setNavigationClient(s > m_navigationClient = WTFMove(navigationClient); > } > >-void WebPageProxy::setLoaderClient(std::unique_ptr<API::LoaderClient>&& loaderClient) >-{ >- if (!loaderClient) { >- m_loaderClient = std::make_unique<API::LoaderClient>(); >- return; >- } >- >- m_loaderClient = WTFMove(loaderClient); >-} >- > void WebPageProxy::setPolicyClient(std::unique_ptr<API::PolicyClient>&& policyClient) > { > if (!policyClient) { >@@ -895,7 +883,6 @@ void WebPageProxy::close() > > resetState(ResetStateReason::PageInvalidated); > >- m_loaderClient = std::make_unique<API::LoaderClient>(); > m_navigationClient = nullptr; > m_policyClient = std::make_unique<API::PolicyClient>(); > m_iconLoadingClient = std::make_unique<API::IconLoadingClient>(); >@@ -1270,8 +1257,8 @@ void WebPageProxy::didChangeBackForwardL > { > PageClientProtector protector(m_pageClient); > >- if (!m_navigationClient || !m_navigationClient->didChangeBackForwardList(*this, added, removed)) >- m_loaderClient->didChangeBackForwardList(*this, added, WTFMove(removed)); >+ if (!m_navigationClient) >+ m_navigationClient->didChangeBackForwardList(*this, added, removed); > > auto transaction = m_pageLoadState.transaction(); > >@@ -1284,17 +1271,14 @@ void WebPageProxy::willGoToBackForwardLi > PageClientProtector protector(m_pageClient); > > if (auto* item = m_backForwardList->itemForID(itemID)) { >- if (m_navigationClient && m_navigationClient->willGoToBackForwardListItem(*this, *item, inPageCache, m_process->transformHandlesToObjects(userData.object()).get())) >- return; >- m_loaderClient->willGoToBackForwardListItem(*this, *item, m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient) >+ m_navigationClient->willGoToBackForwardListItem(*this, *item, inPageCache, m_process->transformHandlesToObjects(userData.object()).get()); > } > } > > bool WebPageProxy::shouldKeepCurrentBackForwardListItemInList(WebBackForwardListItem& item) > { >- PageClientProtector protector(m_pageClient); >- >- return m_loaderClient->shouldKeepCurrentBackForwardListItemInList(*this, item); >+ return true; > } > > bool WebPageProxy::canShowMIMEType(const String& mimeType) >@@ -2172,8 +2156,6 @@ void WebPageProxy::findPlugin(const Stri > auto pluginInformation = createPluginInformationDictionary(plugin, frameURLString, String(), pageURLString, String(), String()); > if (m_navigationClient) > pluginLoadPolicy = m_navigationClient->decidePolicyForPluginLoad(*this, static_cast<PluginModuleLoadPolicy>(pluginLoadPolicy), pluginInformation.get(), unavailabilityDescription); >- else >- pluginLoadPolicy = m_loaderClient->pluginLoadPolicy(*this, static_cast<PluginModuleLoadPolicy>(pluginLoadPolicy), pluginInformation.get(), unavailabilityDescription); > #else > UNUSED_PARAM(frameURLString); > UNUSED_PARAM(pageURLString); >@@ -3370,7 +3352,6 @@ void WebPageProxy::didStartProgress() > m_pageLoadState.didStartProgress(transaction); > > m_pageLoadState.commitChanges(); >- m_loaderClient->didStartProgress(*this); > } > > void WebPageProxy::didChangeProgress(double value) >@@ -3381,7 +3362,6 @@ void WebPageProxy::didChangeProgress(dou > m_pageLoadState.didChangeProgress(transaction, value); > > m_pageLoadState.commitChanges(); >- m_loaderClient->didChangeProgress(*this); > } > > void WebPageProxy::didFinishProgress() >@@ -3392,7 +3372,6 @@ void WebPageProxy::didFinishProgress() > m_pageLoadState.didFinishProgress(transaction); > > m_pageLoadState.commitChanges(); >- m_loaderClient->didFinishProgress(*this); > } > > void WebPageProxy::setNetworkRequestsInProgress(bool networkRequestsInProgress) >@@ -3454,11 +3433,8 @@ void WebPageProxy::didStartProvisionalLo > frame->didStartProvisionalLoad(url); > > m_pageLoadState.commitChanges(); >- if (m_navigationClient) { >- if (frame->isMainFrame()) >- m_navigationClient->didStartProvisionalNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didStartProvisionalLoadForFrame(*this, *frame, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient && frame->isMainFrame()) >+ m_navigationClient->didStartProvisionalNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didReceiveServerRedirectForProvisionalLoadForFrame(uint64_t frameID, uint64_t navigationID, ResourceRequest&& request, const UserData& userData) >@@ -3486,11 +3462,8 @@ void WebPageProxy::didReceiveServerRedir > frame->didReceiveServerRedirectForProvisionalLoad(request.url()); > > m_pageLoadState.commitChanges(); >- if (m_navigationClient) { >- if (frame->isMainFrame()) >- m_navigationClient->didReceiveServerRedirectForProvisionalNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didReceiveServerRedirectForProvisionalLoadForFrame(*this, *frame, frame->isMainFrame() ? navigation.get() : nullptr, m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient && frame->isMainFrame()) >+ m_navigationClient->didReceiveServerRedirectForProvisionalNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::willPerformClientRedirectForFrame(uint64_t frameID, const String& url, double delay) >@@ -3579,8 +3552,7 @@ void WebPageProxy::didFailProvisionalLoa > // FIXME: Get the main frame's current navigation. > m_navigationClient->didFailProvisionalLoadInSubframeWithError(*this, *frame, frameSecurityOrigin, nullptr, error, m_process->transformHandlesToObjects(userData.object()).get()); > } >- } else >- m_loaderClient->didFailProvisionalLoadWithErrorForFrame(*this, *frame, navigation.get(), error, m_process->transformHandlesToObjects(userData.object()).get()); >+ } > > m_failingProvisionalLoadURL = { }; > } >@@ -3672,11 +3644,8 @@ void WebPageProxy::didCommitLoadForFrame > #endif > > m_pageLoadState.commitChanges(); >- if (m_navigationClient) { >- if (frame->isMainFrame()) >- m_navigationClient->didCommitNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didCommitLoadForFrame(*this, *frame, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient && frame->isMainFrame()) >+ m_navigationClient->didCommitNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didFinishDocumentLoadForFrame(uint64_t frameID, uint64_t navigationID, const UserData& userData) >@@ -3696,11 +3665,8 @@ void WebPageProxy::didFinishDocumentLoad > if (frame->isMainFrame() && navigationID) > navigation = &navigationState().navigation(navigationID); > >- if (m_navigationClient) { >- if (frame->isMainFrame()) >- m_navigationClient->didFinishDocumentLoad(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didFinishDocumentLoadForFrame(*this, *frame, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient && frame->isMainFrame()) >+ m_navigationClient->didFinishDocumentLoad(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didFinishLoadForFrame(uint64_t frameID, uint64_t navigationID, const UserData& userData) >@@ -3731,11 +3697,8 @@ void WebPageProxy::didFinishLoadForFrame > frame->didFinishLoad(); > > m_pageLoadState.commitChanges(); >- if (m_navigationClient) { >- if (isMainFrame) >- m_navigationClient->didFinishNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didFinishLoadForFrame(*this, *frame, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient && isMainFrame) >+ m_navigationClient->didFinishNavigation(*this, navigation.get(), m_process->transformHandlesToObjects(userData.object()).get()); > > if (isMainFrame) { > reportPageLoadResult(); >@@ -3778,11 +3741,8 @@ void WebPageProxy::didFailLoadForFrame(u > frame->didFailLoad(); > > m_pageLoadState.commitChanges(); >- if (m_navigationClient) { >- if (frame->isMainFrame()) >- m_navigationClient->didFailNavigationWithError(*this, *frame, navigation.get(), error, m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didFailLoadWithErrorForFrame(*this, *frame, navigation.get(), error, m_process->transformHandlesToObjects(userData.object()).get()); >+ if (m_navigationClient && frame->isMainFrame()) >+ m_navigationClient->didFailNavigationWithError(*this, *frame, navigation.get(), error, m_process->transformHandlesToObjects(userData.object()).get()); > > if (isMainFrame) { > reportPageLoadResult(error); >@@ -3820,14 +3780,12 @@ void WebPageProxy::didSameDocumentNaviga > m_pageLoadState.commitChanges(); > > SameDocumentNavigationType navigationType = static_cast<SameDocumentNavigationType>(opaqueSameDocumentNavigationType); >- if (m_navigationClient) { >- if (isMainFrame) >- m_navigationClient->didSameDocumentNavigation(*this, navigation.get(), navigationType, m_process->transformHandlesToObjects(userData.object()).get()); >- } else >- m_loaderClient->didSameDocumentNavigationForFrame(*this, *frame, navigation.get(), navigationType, m_process->transformHandlesToObjects(userData.object()).get()); > >- if (isMainFrame) >+ if (isMainFrame) { >+ if (m_navigationClient) >+ m_navigationClient->didSameDocumentNavigation(*this, navigation.get(), navigationType, m_process->transformHandlesToObjects(userData.object()).get()); > m_pageClient.didSameDocumentNavigationForMainFrame(navigationType); >+ } > } > > void WebPageProxy::didChangeMainDocument(uint64_t frameID) >@@ -3861,7 +3819,6 @@ void WebPageProxy::didReceiveTitleForFra > frame->didChangeTitle(title); > > m_pageLoadState.commitChanges(); >- m_loaderClient->didReceiveTitleForFrame(*this, title, *frame, m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didFirstLayoutForFrame(uint64_t frameID, const UserData& userData) >@@ -3870,8 +3827,6 @@ void WebPageProxy::didFirstLayoutForFram > > WebFrameProxy* frame = m_process->webFrame(frameID); > MESSAGE_CHECK(frame); >- >- m_loaderClient->didFirstLayoutForFrame(*this, *frame, m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didFirstVisuallyNonEmptyLayoutForFrame(uint64_t frameID, const UserData& userData) >@@ -3881,8 +3836,6 @@ void WebPageProxy::didFirstVisuallyNonEm > WebFrameProxy* frame = m_process->webFrame(frameID); > MESSAGE_CHECK(frame); > >- m_loaderClient->didFirstVisuallyNonEmptyLayoutForFrame(*this, *frame, m_process->transformHandlesToObjects(userData.object()).get()); >- > if (frame->isMainFrame()) > m_pageClient.didFirstVisuallyNonEmptyLayoutForMainFrame(); > } >@@ -3898,8 +3851,6 @@ void WebPageProxy::didReachLayoutMilesto > > if (m_navigationClient) > m_navigationClient->renderingProgressDidChange(*this, static_cast<LayoutMilestones>(layoutMilestones)); >- else >- m_loaderClient->didReachLayoutMilestone(*this, static_cast<LayoutMilestones>(layoutMilestones)); > } > > void WebPageProxy::didDisplayInsecureContentForFrame(uint64_t frameID, const UserData& userData) >@@ -3915,8 +3866,6 @@ void WebPageProxy::didDisplayInsecureCon > > if (m_navigationClient) > m_navigationClient->didDisplayInsecureContent(*this, m_process->transformHandlesToObjects(userData.object()).get()); >- else >- m_loaderClient->didDisplayInsecureContentForFrame(*this, *frame, m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didRunInsecureContentForFrame(uint64_t frameID, const UserData& userData) >@@ -3932,8 +3881,6 @@ void WebPageProxy::didRunInsecureContent > > if (m_navigationClient) > m_navigationClient->didRunInsecureContent(*this, m_process->transformHandlesToObjects(userData.object()).get()); >- else >- m_loaderClient->didRunInsecureContentForFrame(*this, *frame, m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::didDetectXSSForFrame(uint64_t frameID, const UserData& userData) >@@ -3942,8 +3889,6 @@ void WebPageProxy::didDetectXSSForFrame( > > WebFrameProxy* frame = m_process->webFrame(frameID); > MESSAGE_CHECK(frame); >- >- m_loaderClient->didDetectXSSForFrame(*this, *frame, m_process->transformHandlesToObjects(userData.object()).get()); > } > > void WebPageProxy::mainFramePluginHandlesPageScaleGestureDidChange(bool mainFramePluginHandlesPageScaleGesture) >@@ -4193,11 +4138,8 @@ void WebPageProxy::didNavigateWithNaviga > MESSAGE_CHECK(frame); > MESSAGE_CHECK(frame->page() == this); > >- if (m_historyClient) { >- if (frame->isMainFrame()) >- m_historyClient->didNavigateWithNavigationData(*this, store); >- } else >- m_loaderClient->didNavigateWithNavigationData(*this, store, *frame); >+ if (m_historyClient && frame->isMainFrame()) >+ m_historyClient->didNavigateWithNavigationData(*this, store); > process().processPool().historyClient().didNavigateWithNavigationData(process().processPool(), *this, store, *frame); > } > >@@ -4215,11 +4157,8 @@ void WebPageProxy::didPerformClientRedir > MESSAGE_CHECK_URL(sourceURLString); > MESSAGE_CHECK_URL(destinationURLString); > >- if (m_historyClient) { >- if (frame->isMainFrame()) >- m_historyClient->didPerformClientRedirect(*this, sourceURLString, destinationURLString); >- } else >- m_loaderClient->didPerformClientRedirect(*this, sourceURLString, destinationURLString, *frame); >+ if (m_historyClient && frame->isMainFrame()) >+ m_historyClient->didPerformClientRedirect(*this, sourceURLString, destinationURLString); > process().processPool().historyClient().didPerformClientRedirect(process().processPool(), *this, sourceURLString, destinationURLString, *frame); > } > >@@ -4237,11 +4176,8 @@ void WebPageProxy::didPerformServerRedir > MESSAGE_CHECK_URL(sourceURLString); > MESSAGE_CHECK_URL(destinationURLString); > >- if (m_historyClient) { >- if (frame->isMainFrame()) >- m_historyClient->didPerformServerRedirect(*this, sourceURLString, destinationURLString); >- } else >- m_loaderClient->didPerformServerRedirect(*this, sourceURLString, destinationURLString, *frame); >+ if (m_historyClient && frame->isMainFrame()) >+ m_historyClient->didPerformServerRedirect(*this, sourceURLString, destinationURLString); > process().processPool().historyClient().didPerformServerRedirect(process().processPool(), *this, sourceURLString, destinationURLString, *frame); > } > >@@ -4255,11 +4191,8 @@ void WebPageProxy::didUpdateHistoryTitle > > MESSAGE_CHECK_URL(url); > >- if (m_historyClient) { >- if (frame->isMainFrame()) >- m_historyClient->didUpdateHistoryTitle(*this, title, url); >- } else >- m_loaderClient->didUpdateHistoryTitle(*this, title, url, *frame); >+ if (m_historyClient && frame->isMainFrame()) >+ m_historyClient->didUpdateHistoryTitle(*this, title, url); > process().processPool().historyClient().didUpdateHistoryTitle(process().processPool(), *this, title, url, *frame); > } > >@@ -4456,8 +4389,7 @@ void WebPageProxy::webGLPolicyForURL(URL > m_navigationClient->webGLLoadPolicy(*this, url, [reply = WTFMove(reply)] (WebGLLoadPolicy policy) mutable { > reply(static_cast<uint32_t>(policy)); > }); >- } else >- reply(static_cast<uint32_t>(m_loaderClient->webGLLoadPolicy(*this, url))); >+ } > } > > void WebPageProxy::resolveWebGLPolicyForURL(URL&& url, Messages::WebPageProxy::ResolveWebGLPolicyForURL::DelayedReply&& reply) >@@ -4466,8 +4398,7 @@ void WebPageProxy::resolveWebGLPolicyFor > m_navigationClient->resolveWebGLLoadPolicy(*this, url, [reply = WTFMove(reply)] (WebGLLoadPolicy policy) mutable { > reply(static_cast<uint32_t>(policy)); > }); >- } else >- reply(static_cast<uint32_t>(m_loaderClient->resolveWebGLLoadPolicy(*this, url))); >+ } > } > #endif // ENABLE(WEBGL) > >@@ -5882,8 +5813,6 @@ void WebPageProxy::processDidBecomeUnres > > if (m_navigationClient) > m_navigationClient->processDidBecomeUnresponsive(*this); >- else >- m_loaderClient->processDidBecomeUnresponsive(*this); > } > > void WebPageProxy::processDidBecomeResponsive() >@@ -5895,8 +5824,6 @@ void WebPageProxy::processDidBecomeRespo > > if (m_navigationClient) > m_navigationClient->processDidBecomeResponsive(*this); >- else >- m_loaderClient->processDidBecomeResponsive(*this); > } > > void WebPageProxy::willChangeProcessIsResponsive() >@@ -5974,8 +5901,6 @@ void WebPageProxy::dispatchProcessDidTer > bool handledByClient = false; > if (m_navigationClient) > handledByClient = m_navigationClient->processDidTerminate(*this, reason); >- else if (reason != ProcessTerminationReason::RequestedByClient) >- handledByClient = m_loaderClient->processDidCrash(*this); > > if (!handledByClient && shouldReloadAfterProcessTermination(reason)) > tryReloadAfterProcessTermination(); >@@ -6344,9 +6269,6 @@ void WebPageProxy::gamepadActivity(const > > void WebPageProxy::didReceiveAuthenticationChallengeProxy(uint64_t frameID, Ref<AuthenticationChallengeProxy>&& authenticationChallenge) > { >- WebFrameProxy* frame = m_process->webFrame(frameID); >- MESSAGE_CHECK(frame); >- > #if HAVE(SEC_KEY_PROXY) > ASSERT(authenticationChallenge->protectionSpace()); > if (authenticationChallenge->protectionSpace()->authenticationScheme() == ProtectionSpaceAuthenticationSchemeClientCertificateRequested) { >@@ -6358,8 +6280,6 @@ void WebPageProxy::didReceiveAuthenticat > > if (m_navigationClient) > m_navigationClient->didReceiveAuthenticationChallenge(*this, authenticationChallenge.get()); >- else >- m_loaderClient->didReceiveAuthenticationChallengeInFrame(*this, *frame, authenticationChallenge.get()); > } > > void WebPageProxy::exceededDatabaseQuota(uint64_t frameID, const String& originIdentifier, const String& databaseName, const String& displayName, uint64_t currentQuota, uint64_t currentOriginUsage, uint64_t currentDatabaseUsage, uint64_t expectedUsage, Messages::WebPageProxy::ExceededDatabaseQuota::DelayedReply&& reply) >@@ -6596,9 +6516,7 @@ void WebPageProxy::pageExtendedBackgroun > #if ENABLE(NETSCAPE_PLUGIN_API) > void WebPageProxy::didFailToInitializePlugin(const String& mimeType, const String& frameURLString, const String& pageURLString) > { >- if (m_navigationClient->didFailToInitializePlugIn(*this, createPluginInformationDictionary(mimeType, frameURLString, pageURLString).get())) >- return; >- m_loaderClient->didFailToInitializePlugin(*this, createPluginInformationDictionary(mimeType, frameURLString, pageURLString).get()); >+ m_navigationClient->didFailToInitializePlugIn(*this, createPluginInformationDictionary(mimeType, frameURLString, pageURLString).get()); > } > > void WebPageProxy::didBlockInsecurePluginVersion(const String& mimeType, const String& pluginURLString, const String& frameURLString, const String& pageURLString, bool replacementObscured) >@@ -6607,9 +6525,7 @@ void WebPageProxy::didBlockInsecurePlugi > PluginModuleInfo plugin = m_process->processPool().pluginInfoStore().findPlugin(newMimeType, URL(URL(), pluginURLString)); > auto pluginInformation = createPluginInformationDictionary(plugin, frameURLString, mimeType, pageURLString, String(), String(), replacementObscured); > >- if (m_navigationClient->didBlockInsecurePluginVersion(*this, pluginInformation.get())) >- return; >- m_loaderClient->didBlockInsecurePluginVersion(*this, pluginInformation.get()); >+ m_navigationClient->didBlockInsecurePluginVersion(*this, pluginInformation.get()); > } > #endif // ENABLE(NETSCAPE_PLUGIN_API) > >@@ -7126,8 +7042,6 @@ void WebPageProxy::navigationGestureDidB > > if (m_navigationClient) > m_navigationClient->didBeginNavigationGesture(*this); >- else >- m_loaderClient->navigationGestureDidBegin(*this); > } > > void WebPageProxy::navigationGestureWillEnd(bool willNavigate, WebBackForwardListItem& item) >@@ -7138,8 +7052,6 @@ void WebPageProxy::navigationGestureWill > > if (m_navigationClient) > m_navigationClient->willEndNavigationGesture(*this, willNavigate, item); >- else >- m_loaderClient->navigationGestureWillEnd(*this, willNavigate, item); > } > > void WebPageProxy::navigationGestureDidEnd(bool willNavigate, WebBackForwardListItem& item) >@@ -7150,8 +7062,6 @@ void WebPageProxy::navigationGestureDidE > > if (m_navigationClient) > m_navigationClient->didEndNavigationGesture(*this, willNavigate, item); >- else >- m_loaderClient->navigationGestureDidEnd(*this, willNavigate, item); > } > > void WebPageProxy::navigationGestureDidEnd() >Index: Source/WebKit/UIProcess/WebPageProxy.h >=================================================================== >--- Source/WebKit/UIProcess/WebPageProxy.h (revision 235090) >+++ Source/WebKit/UIProcess/WebPageProxy.h (working copy) >@@ -428,7 +428,6 @@ public: > void setFormClient(std::unique_ptr<API::FormClient>&&); > void setNavigationClient(std::unique_ptr<API::NavigationClient>&&); > void setHistoryClient(std::unique_ptr<API::HistoryClient>&&); >- void setLoaderClient(std::unique_ptr<API::LoaderClient>&&); > void setPolicyClient(std::unique_ptr<API::PolicyClient>&&); > void setInjectedBundleClient(const WKPageInjectedBundleClientBase*); > WebPageInjectedBundleClient* injectedBundleClient() { return m_injectedBundleClient.get(); } >@@ -1824,7 +1823,6 @@ private: > PageClient& m_pageClient; > Ref<API::PageConfiguration> m_configuration; > >- std::unique_ptr<API::LoaderClient> m_loaderClient; > std::unique_ptr<API::PolicyClient> m_policyClient; > std::unique_ptr<API::NavigationClient> m_navigationClient; > std::unique_ptr<API::HistoryClient> m_historyClient; >Index: Source/WebKit/UIProcess/API/APILoaderClient.h >=================================================================== >--- Source/WebKit/UIProcess/API/APILoaderClient.h (revision 235090) >+++ Source/WebKit/UIProcess/API/APILoaderClient.h (nonexistent) >@@ -1,124 +0,0 @@ >-/* >- * Copyright (C) 2014 Apple Inc. All rights reserved. >- * >- * Redistribution and use in source and binary forms, with or without >- * modification, are permitted provided that the following conditions >- * are met: >- * 1. Redistributions of source code must retain the above copyright >- * notice, this list of conditions and the following disclaimer. >- * 2. Redistributions in binary form must reproduce the above copyright >- * notice, this list of conditions and the following disclaimer in the >- * documentation and/or other materials provided with the distribution. >- * >- * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >- * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >- * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >- * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >- * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >- * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >- * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >- * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >- * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >- * THE POSSIBILITY OF SUCH DAMAGE. >- */ >- >-#ifndef APILoaderClient_h >-#define APILoaderClient_h >- >-#include "APIData.h" >-#include "PluginModuleInfo.h" >-#include "SameDocumentNavigationType.h" >-#include <WebCore/FrameLoaderTypes.h> >-#include <WebCore/LayoutMilestones.h> >-#include <wtf/Forward.h> >- >-namespace WebCore { >-class ResourceError; >-} >- >-namespace WebKit { >-class AuthenticationChallengeProxy; >-class QuickLookDocumentData; >-class WebBackForwardListItem; >-class WebFrameProxy; >-class WebPageProxy; >-class WebProtectionSpace; >-struct WebNavigationDataStore; >-} >- >-namespace API { >- >-class Dictionary; >-class Navigation; >-class Object; >- >-class LoaderClient { >-public: >- virtual ~LoaderClient() { } >- >- virtual void didStartProvisionalLoadForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, API::Object*) { } >- virtual void didReceiveServerRedirectForProvisionalLoadForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, API::Object*) { } >- virtual void didFailProvisionalLoadWithErrorForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, const WebCore::ResourceError&, API::Object*) { } >- virtual void didCommitLoadForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, API::Object*) { } >- virtual void didFinishDocumentLoadForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, API::Object*) { } >- virtual void didFinishLoadForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, API::Object*) { } >- virtual void didFailLoadWithErrorForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, const WebCore::ResourceError&, API::Object*) { } >- virtual void didSameDocumentNavigationForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Navigation*, WebKit::SameDocumentNavigationType, API::Object*) { } >- virtual void didReceiveTitleForFrame(WebKit::WebPageProxy&, const WTF::String&, WebKit::WebFrameProxy&, API::Object*) { } >- virtual void didFirstLayoutForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Object*) { } >- >- // FIXME: We should consider removing didFirstVisuallyNonEmptyLayoutForFrame since it is replaced by didLayout. >- virtual void didFirstVisuallyNonEmptyLayoutForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Object*) { } >- >- virtual void didDisplayInsecureContentForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Object*) { } >- virtual void didRunInsecureContentForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Object*) { } >- virtual void didDetectXSSForFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, API::Object*) { } >- >- virtual void didReachLayoutMilestone(WebKit::WebPageProxy&, WebCore::LayoutMilestones) { } >- >- virtual bool canAuthenticateAgainstProtectionSpaceInFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, WebKit::WebProtectionSpace*) { return false; } >- virtual void didReceiveAuthenticationChallengeInFrame(WebKit::WebPageProxy&, WebKit::WebFrameProxy&, WebKit::AuthenticationChallengeProxy&) { } >- >- virtual void didStartProgress(WebKit::WebPageProxy&) { } >- virtual void didChangeProgress(WebKit::WebPageProxy&) { } >- virtual void didFinishProgress(WebKit::WebPageProxy&) { } >- >- // FIXME: These functions should not be part of this client. >- virtual void processDidBecomeUnresponsive(WebKit::WebPageProxy&) { } >- virtual void processDidBecomeResponsive(WebKit::WebPageProxy&) { } >- virtual bool processDidCrash(WebKit::WebPageProxy&) { return false; } >- >- virtual void didChangeBackForwardList(WebKit::WebPageProxy&, WebKit::WebBackForwardListItem*, Vector<Ref<WebKit::WebBackForwardListItem>>&&) { } >- virtual bool shouldKeepCurrentBackForwardListItemInList(WebKit::WebPageProxy&, WebKit::WebBackForwardListItem&) { return true; } >- virtual void willGoToBackForwardListItem(WebKit::WebPageProxy&, WebKit::WebBackForwardListItem&, API::Object*) { } >- >- virtual void didNavigateWithNavigationData(WebKit::WebPageProxy&, const WebKit::WebNavigationDataStore&, WebKit::WebFrameProxy&) { } >- virtual void didPerformClientRedirect(WebKit::WebPageProxy&, const WTF::String&, const WTF::String&, WebKit::WebFrameProxy&) { } >- virtual void didPerformServerRedirect(WebKit::WebPageProxy&, const WTF::String&, const WTF::String&, WebKit::WebFrameProxy&) { } >- virtual void didUpdateHistoryTitle(WebKit::WebPageProxy&, const WTF::String&, const WTF::String&, WebKit::WebFrameProxy&) { } >- >- virtual void navigationGestureDidBegin(WebKit::WebPageProxy&) { } >- virtual void navigationGestureWillEnd(WebKit::WebPageProxy&, bool willNavigate, WebKit::WebBackForwardListItem&) { } >- virtual void navigationGestureDidEnd(WebKit::WebPageProxy&, bool willNavigate, WebKit::WebBackForwardListItem&) { } >- >-#if ENABLE(NETSCAPE_PLUGIN_API) >- virtual WebKit::PluginModuleLoadPolicy pluginLoadPolicy(WebKit::WebPageProxy&, WebKit::PluginModuleLoadPolicy currentPluginLoadPolicy, API::Dictionary&, WTF::String& /* unavailabilityDescription */) { return currentPluginLoadPolicy; } >- virtual void didFailToInitializePlugin(WebKit::WebPageProxy&, API::Dictionary&) { } >- virtual void didBlockInsecurePluginVersion(WebKit::WebPageProxy&, API::Dictionary&) { } >-#endif // ENABLE(NETSCAPE_PLUGIN_API) >- >-#if ENABLE(WEBGL) >- virtual WebCore::WebGLLoadPolicy webGLLoadPolicy(WebKit::WebPageProxy&, const WTF::String&) const { return WebCore::WebGLLoadPolicy::WebGLAllowCreation; } >- virtual WebCore::WebGLLoadPolicy resolveWebGLLoadPolicy(WebKit::WebPageProxy&, const WTF::String&) const { return WebCore::WebGLLoadPolicy::WebGLAllowCreation; } >-#endif // ENABLE(WEBGL) >- >-#if USE(QUICK_LOOK) >- virtual void didStartLoadForQuickLookDocumentInMainFrame(const WTF::String& fileName, const WTF::String& uti) { } >- virtual void didFinishLoadForQuickLookDocumentInMainFrame(const WebKit::QuickLookDocumentData&) { } >-#endif >-}; >- >-} // namespace API >- >-#endif // APILoaderClient_h >Index: Source/WebKit/UIProcess/API/C/WKPage.cpp >=================================================================== >--- Source/WebKit/UIProcess/API/C/WKPage.cpp (revision 235090) >+++ Source/WebKit/UIProcess/API/C/WKPage.cpp (working copy) >@@ -37,7 +37,6 @@ > #include "APIFrameInfo.h" > #include "APIGeometry.h" > #include "APIHitTestResult.h" >-#include "APILoaderClient.h" > #include "APINavigation.h" > #include "APINavigationAction.h" > #include "APINavigationClient.h" >@@ -1035,333 +1034,9 @@ void WKPageSetPageFormClient(WKPageRef p > toImpl(pageRef)->setFormClient(std::make_unique<WebFormClient>(wkClient)); > } > >-void WKPageSetPageLoaderClient(WKPageRef pageRef, const WKPageLoaderClientBase* wkClient) >+NO_RETURN_DUE_TO_ASSERT void WKPageSetPageLoaderClient(WKPageRef, const WKPageLoaderClientBase*) > { >- class LoaderClient : public API::Client<WKPageLoaderClientBase>, public API::LoaderClient { >- public: >- explicit LoaderClient(const WKPageLoaderClientBase* client) >- { >- initialize(client); >- } >- >- private: >- void didStartProvisionalLoadForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, API::Object* userData) override >- { >- if (!m_client.didStartProvisionalLoadForFrame) >- return; >- >- m_client.didStartProvisionalLoadForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didReceiveServerRedirectForProvisionalLoadForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, API::Object* userData) override >- { >- if (!m_client.didReceiveServerRedirectForProvisionalLoadForFrame) >- return; >- >- m_client.didReceiveServerRedirectForProvisionalLoadForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didFailProvisionalLoadWithErrorForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, const ResourceError& error, API::Object* userData) override >- { >- if (!m_client.didFailProvisionalLoadWithErrorForFrame) >- return; >- >- m_client.didFailProvisionalLoadWithErrorForFrame(toAPI(&page), toAPI(&frame), toAPI(error), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didCommitLoadForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, API::Object* userData) override >- { >- if (!m_client.didCommitLoadForFrame) >- return; >- >- m_client.didCommitLoadForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didFinishDocumentLoadForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, API::Object* userData) override >- { >- if (!m_client.didFinishDocumentLoadForFrame) >- return; >- >- m_client.didFinishDocumentLoadForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didFinishLoadForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, API::Object* userData) override >- { >- if (!m_client.didFinishLoadForFrame) >- return; >- >- m_client.didFinishLoadForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didFailLoadWithErrorForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, const ResourceError& error, API::Object* userData) override >- { >- if (!m_client.didFailLoadWithErrorForFrame) >- return; >- >- m_client.didFailLoadWithErrorForFrame(toAPI(&page), toAPI(&frame), toAPI(error), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didSameDocumentNavigationForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Navigation*, SameDocumentNavigationType type, API::Object* userData) override >- { >- if (!m_client.didSameDocumentNavigationForFrame) >- return; >- >- m_client.didSameDocumentNavigationForFrame(toAPI(&page), toAPI(&frame), toAPI(type), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didReceiveTitleForFrame(WebPageProxy& page, const String& title, WebFrameProxy& frame, API::Object* userData) override >- { >- if (!m_client.didReceiveTitleForFrame) >- return; >- >- m_client.didReceiveTitleForFrame(toAPI(&page), toAPI(title.impl()), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didFirstLayoutForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Object* userData) override >- { >- if (!m_client.didFirstLayoutForFrame) >- return; >- >- m_client.didFirstLayoutForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didFirstVisuallyNonEmptyLayoutForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Object* userData) override >- { >- if (!m_client.didFirstVisuallyNonEmptyLayoutForFrame) >- return; >- >- m_client.didFirstVisuallyNonEmptyLayoutForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didReachLayoutMilestone(WebPageProxy& page, LayoutMilestones milestones) override >- { >- if (!m_client.didLayout) >- return; >- >- m_client.didLayout(toAPI(&page), toWKLayoutMilestones(milestones), nullptr, m_client.base.clientInfo); >- } >- >- void didDisplayInsecureContentForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Object* userData) override >- { >- if (!m_client.didDisplayInsecureContentForFrame) >- return; >- >- m_client.didDisplayInsecureContentForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didRunInsecureContentForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Object* userData) override >- { >- if (!m_client.didRunInsecureContentForFrame) >- return; >- >- m_client.didRunInsecureContentForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- void didDetectXSSForFrame(WebPageProxy& page, WebFrameProxy& frame, API::Object* userData) override >- { >- if (!m_client.didDetectXSSForFrame) >- return; >- >- m_client.didDetectXSSForFrame(toAPI(&page), toAPI(&frame), toAPI(userData), m_client.base.clientInfo); >- } >- >- bool canAuthenticateAgainstProtectionSpaceInFrame(WebPageProxy& page, WebFrameProxy& frame, WebProtectionSpace* protectionSpace) override >- { >- if (!m_client.canAuthenticateAgainstProtectionSpaceInFrame) >- return false; >- >- return m_client.canAuthenticateAgainstProtectionSpaceInFrame(toAPI(&page), toAPI(&frame), toAPI(protectionSpace), m_client.base.clientInfo); >- } >- >- void didReceiveAuthenticationChallengeInFrame(WebPageProxy& page, WebFrameProxy& frame, AuthenticationChallengeProxy& authenticationChallenge) override >- { >- if (!m_client.didReceiveAuthenticationChallengeInFrame) >- return; >- >- m_client.didReceiveAuthenticationChallengeInFrame(toAPI(&page), toAPI(&frame), toAPI(&authenticationChallenge), m_client.base.clientInfo); >- } >- >- void didStartProgress(WebPageProxy& page) override >- { >- if (!m_client.didStartProgress) >- return; >- >- m_client.didStartProgress(toAPI(&page), m_client.base.clientInfo); >- } >- >- void didChangeProgress(WebPageProxy& page) override >- { >- if (!m_client.didChangeProgress) >- return; >- >- m_client.didChangeProgress(toAPI(&page), m_client.base.clientInfo); >- } >- >- void didFinishProgress(WebPageProxy& page) override >- { >- if (!m_client.didFinishProgress) >- return; >- >- m_client.didFinishProgress(toAPI(&page), m_client.base.clientInfo); >- } >- >- void processDidBecomeUnresponsive(WebPageProxy& page) override >- { >- if (!m_client.processDidBecomeUnresponsive) >- return; >- >- m_client.processDidBecomeUnresponsive(toAPI(&page), m_client.base.clientInfo); >- } >- >- void processDidBecomeResponsive(WebPageProxy& page) override >- { >- if (!m_client.processDidBecomeResponsive) >- return; >- >- m_client.processDidBecomeResponsive(toAPI(&page), m_client.base.clientInfo); >- } >- >- bool processDidCrash(WebPageProxy& page) override >- { >- if (!m_client.processDidCrash) >- return false; >- >- m_client.processDidCrash(toAPI(&page), m_client.base.clientInfo); >- return true; >- } >- >- void didChangeBackForwardList(WebPageProxy& page, WebBackForwardListItem* addedItem, Vector<Ref<WebBackForwardListItem>>&& removedItems) override >- { >- if (!m_client.didChangeBackForwardList) >- return; >- >- RefPtr<API::Array> removedItemsArray; >- if (!removedItems.isEmpty()) { >- Vector<RefPtr<API::Object>> removedItemsVector; >- removedItemsVector.reserveInitialCapacity(removedItems.size()); >- for (auto& removedItem : removedItems) >- removedItemsVector.append(WTFMove(removedItem)); >- >- removedItemsArray = API::Array::create(WTFMove(removedItemsVector)); >- } >- >- m_client.didChangeBackForwardList(toAPI(&page), toAPI(addedItem), toAPI(removedItemsArray.get()), m_client.base.clientInfo); >- } >- >- bool shouldKeepCurrentBackForwardListItemInList(WebKit::WebPageProxy& page, WebKit::WebBackForwardListItem& item) override >- { >- if (!m_client.shouldKeepCurrentBackForwardListItemInList) >- return true; >- >- return m_client.shouldKeepCurrentBackForwardListItemInList(toAPI(&page), toAPI(&item), m_client.base.clientInfo); >- } >- >- void willGoToBackForwardListItem(WebPageProxy& page, WebBackForwardListItem& item, API::Object* userData) override >- { >- if (m_client.willGoToBackForwardListItem) >- m_client.willGoToBackForwardListItem(toAPI(&page), toAPI(&item), toAPI(userData), m_client.base.clientInfo); >- } >- >- void navigationGestureDidBegin(WebPageProxy& page) override >- { >- if (m_client.navigationGestureDidBegin) >- m_client.navigationGestureDidBegin(toAPI(&page), m_client.base.clientInfo); >- } >- >- void navigationGestureWillEnd(WebPageProxy& page, bool willNavigate, WebBackForwardListItem& item) override >- { >- if (m_client.navigationGestureWillEnd) >- m_client.navigationGestureWillEnd(toAPI(&page), willNavigate, toAPI(&item), m_client.base.clientInfo); >- } >- >- void navigationGestureDidEnd(WebPageProxy& page, bool willNavigate, WebBackForwardListItem& item) override >- { >- if (m_client.navigationGestureDidEnd) >- m_client.navigationGestureDidEnd(toAPI(&page), willNavigate, toAPI(&item), m_client.base.clientInfo); >- } >- >-#if ENABLE(NETSCAPE_PLUGIN_API) >- void didFailToInitializePlugin(WebPageProxy& page, API::Dictionary& pluginInformation) final >- { >- if (m_client.didFailToInitializePlugin_deprecatedForUseWithV0) >- m_client.didFailToInitializePlugin_deprecatedForUseWithV0(toAPI(&page), toAPI(pluginInformation.get<API::String>(pluginInformationMIMETypeKey())), m_client.base.clientInfo); >- >- if (m_client.pluginDidFail_deprecatedForUseWithV1) >- m_client.pluginDidFail_deprecatedForUseWithV1(toAPI(&page), kWKErrorCodeCannotLoadPlugIn, toAPI(pluginInformation.get<API::String>(pluginInformationMIMETypeKey())), 0, 0, m_client.base.clientInfo); >- >- if (m_client.pluginDidFail) >- m_client.pluginDidFail(toAPI(&page), kWKErrorCodeCannotLoadPlugIn, toAPI(&pluginInformation), m_client.base.clientInfo); >- } >- >- void didBlockInsecurePluginVersion(WebPageProxy& page, API::Dictionary& pluginInformation) override >- { >- if (m_client.pluginDidFail_deprecatedForUseWithV1) >- m_client.pluginDidFail_deprecatedForUseWithV1(toAPI(&page), kWKErrorCodeInsecurePlugInVersion, toAPI(pluginInformation.get<API::String>(pluginInformationMIMETypeKey())), toAPI(pluginInformation.get<API::String>(pluginInformationBundleIdentifierKey())), toAPI(pluginInformation.get<API::String>(pluginInformationBundleVersionKey())), m_client.base.clientInfo); >- >- if (m_client.pluginDidFail) >- m_client.pluginDidFail(toAPI(&page), kWKErrorCodeInsecurePlugInVersion, toAPI(&pluginInformation), m_client.base.clientInfo); >- } >- >- PluginModuleLoadPolicy pluginLoadPolicy(WebPageProxy& page, PluginModuleLoadPolicy currentPluginLoadPolicy, API::Dictionary& pluginInformation, String& unavailabilityDescription) override >- { >- WKStringRef unavailabilityDescriptionOut = 0; >- PluginModuleLoadPolicy loadPolicy = currentPluginLoadPolicy; >- >- if (m_client.pluginLoadPolicy_deprecatedForUseWithV2) >- loadPolicy = toPluginModuleLoadPolicy(m_client.pluginLoadPolicy_deprecatedForUseWithV2(toAPI(&page), toWKPluginLoadPolicy(currentPluginLoadPolicy), toAPI(&pluginInformation), m_client.base.clientInfo)); >- else if (m_client.pluginLoadPolicy) >- loadPolicy = toPluginModuleLoadPolicy(m_client.pluginLoadPolicy(toAPI(&page), toWKPluginLoadPolicy(currentPluginLoadPolicy), toAPI(&pluginInformation), &unavailabilityDescriptionOut, m_client.base.clientInfo)); >- >- if (unavailabilityDescriptionOut) { >- RefPtr<API::String> webUnavailabilityDescription = adoptRef(toImpl(unavailabilityDescriptionOut)); >- unavailabilityDescription = webUnavailabilityDescription->string(); >- } >- >- return loadPolicy; >- } >-#endif // ENABLE(NETSCAPE_PLUGIN_API) >- >-#if ENABLE(WEBGL) >- WebCore::WebGLLoadPolicy webGLLoadPolicy(WebPageProxy& page, const String& url) const override >- { >- WebCore::WebGLLoadPolicy loadPolicy = WebGLAllowCreation; >- >- if (m_client.webGLLoadPolicy) >- loadPolicy = toWebGLLoadPolicy(m_client.webGLLoadPolicy(toAPI(&page), toAPI(url.impl()), m_client.base.clientInfo)); >- >- return loadPolicy; >- } >- >- WebCore::WebGLLoadPolicy resolveWebGLLoadPolicy(WebPageProxy& page, const String& url) const override >- { >- WebCore::WebGLLoadPolicy loadPolicy = WebGLAllowCreation; >- >- if (m_client.resolveWebGLLoadPolicy) >- loadPolicy = toWebGLLoadPolicy(m_client.resolveWebGLLoadPolicy(toAPI(&page), toAPI(url.impl()), m_client.base.clientInfo)); >- >- return loadPolicy; >- } >- >-#endif // ENABLE(WEBGL) >- }; >- >- WebPageProxy* webPageProxy = toImpl(pageRef); >- >- auto loaderClient = std::make_unique<LoaderClient>(wkClient); >- >- // It would be nice to get rid of this code and transition all clients to using didLayout instead of >- // didFirstLayoutInFrame and didFirstVisuallyNonEmptyLayoutInFrame. In the meantime, this is required >- // for backwards compatibility. >- WebCore::LayoutMilestones milestones = 0; >- if (loaderClient->client().didFirstLayoutForFrame) >- milestones |= WebCore::DidFirstLayout; >- if (loaderClient->client().didFirstVisuallyNonEmptyLayoutForFrame) >- milestones |= WebCore::DidFirstVisuallyNonEmptyLayout; >- >- if (milestones) >- webPageProxy->process().send(Messages::WebPage::ListenForLayoutMilestones(milestones), webPageProxy->pageID()); >- >- webPageProxy->setLoaderClient(WTFMove(loaderClient)); >+ RELEASE_ASSERT_NOT_REACHED(); > } > > void WKPageSetPagePolicyClient(WKPageRef pageRef, const WKPagePolicyClientBase* wkClient) >Index: Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm >=================================================================== >--- Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm (revision 235090) >+++ Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm (working copy) >@@ -56,7 +56,6 @@ > #import <wtf/text/TextStream.h> > > #if USE(QUICK_LOOK) >-#import "APILoaderClient.h" > #import "APINavigationClient.h" > #import <wtf/text/WTFString.h> > #endif >@@ -1131,16 +1130,12 @@ void WebPageProxy::didStartLoadForQuickL > static_assert(notFound + 1 == 0, "The following line assumes WTF::notFound equals -1"); > if (m_navigationClient) > m_navigationClient->didStartLoadForQuickLookDocumentInMainFrame(fileName.substring(fileName.reverseFind('/') + 1), uti); >- else >- m_loaderClient->didStartLoadForQuickLookDocumentInMainFrame(fileName.substring(fileName.reverseFind('/') + 1), uti); > } > > void WebPageProxy::didFinishLoadForQuickLookDocumentInMainFrame(const QuickLookDocumentData& data) > { > if (m_navigationClient) > m_navigationClient->didFinishLoadForQuickLookDocumentInMainFrame(data); >- else >- m_loaderClient->didFinishLoadForQuickLookDocumentInMainFrame(data); > } > > void WebPageProxy::didRequestPasswordForQuickLookDocumentInMainFrame(const String& fileName) >Index: Source/WebKit/WebKit.xcodeproj/project.pbxproj >=================================================================== >--- Source/WebKit/WebKit.xcodeproj/project.pbxproj (revision 235090) >+++ Source/WebKit/WebKit.xcodeproj/project.pbxproj (working copy) >@@ -200,7 +200,6 @@ > 1A2161B111F37664008AD0F5 /* NPRuntimeObjectMap.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2161AF11F37664008AD0F5 /* NPRuntimeObjectMap.cpp */; }; > 1A2162B011F38971008AD0F5 /* NPRuntimeUtilities.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 1A2162AE11F38971008AD0F5 /* NPRuntimeUtilities.cpp */; }; > 1A2162B111F38971008AD0F5 /* NPRuntimeUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A2162AF11F38971008AD0F5 /* NPRuntimeUtilities.h */; }; >- 1A2464F31891E45100234C5B /* APILoaderClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A2464F21891E45100234C5B /* APILoaderClient.h */; }; > 1A24B5F311F531E800C38269 /* MachUtilities.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A24B5F111F531E800C38269 /* MachUtilities.h */; }; > 1A24BED5120894D100FBB059 /* SharedMemory.h in Headers */ = {isa = PBXBuildFile; fileRef = 1A24BED3120894D100FBB059 /* SharedMemory.h */; }; > 1A256E3718A1A788006FB922 /* WKNavigationAction.mm in Sources */ = {isa = PBXBuildFile; fileRef = 1A256E3518A1A788006FB922 /* WKNavigationAction.mm */; }; >@@ -2603,7 +2602,6 @@ > 1A2162AF11F38971008AD0F5 /* NPRuntimeUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = NPRuntimeUtilities.h; sourceTree = "<group>"; }; > 1A22F0FF1289FCD90085E74F /* WKBundlePageOverlay.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKBundlePageOverlay.h; sourceTree = "<group>"; }; > 1A22F1001289FCD90085E74F /* WKBundlePageOverlay.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WKBundlePageOverlay.cpp; sourceTree = "<group>"; }; >- 1A2464F21891E45100234C5B /* APILoaderClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = APILoaderClient.h; sourceTree = "<group>"; }; > 1A24B5F011F531E800C38269 /* MachUtilities.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = MachUtilities.cpp; sourceTree = "<group>"; }; > 1A24B5F111F531E800C38269 /* MachUtilities.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MachUtilities.h; sourceTree = "<group>"; }; > 1A24BED3120894D100FBB059 /* SharedMemory.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SharedMemory.h; sourceTree = "<group>"; }; >@@ -7914,7 +7912,6 @@ > 5143B2611DDD0DA00014FAC6 /* APIIconLoadingClient.h */, > 7A8A9D571EF119AA009801AE /* APIInjectedBundleClient.h */, > 7CE4D2061A46775700C7F152 /* APILegacyContextHistoryClient.h */, >- 1A2464F21891E45100234C5B /* APILoaderClient.h */, > 7CD3A4801A5D02FA009623B8 /* APINavigation.cpp */, > 7CD3A4811A5D02FA009623B8 /* APINavigation.h */, > 2DF9EEEA1A7836EE00B6CFBE /* APINavigationAction.h */, >@@ -9315,7 +9312,6 @@ > 7A8A9D5C1EF14598009801AE /* APIInjectedBundlePageResourceLoadClient.h in Headers */, > 3769079A18F31CB2001DFF04 /* APIInjectedBundlePageUIClient.h in Headers */, > 7CE4D2071A46776100C7F152 /* APILegacyContextHistoryClient.h in Headers */, >- 1A2464F31891E45100234C5B /* APILoaderClient.h in Headers */, > 7CD3A4831A5D02FA009623B8 /* APINavigation.h in Headers */, > 2DF9EEEC1A7836EE00B6CFBE /* APINavigationAction.h in Headers */, > 2DD9EB2D1A6F012500BB1267 /* APINavigationClient.h in Headers */,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 188760
:
347549
|
347555
|
347564
|
347629