-
carlosgc@webkit.org authored
https://bugs.webkit.org/show_bug.cgi?id=97895 Reviewed by Martin Robinson. Source/WebCore: * platform/network/NetworkingContext.h: (NetworkingContext): Add initiatingPageID(). * platform/network/ResourceHandle.h: (ResourceHandle): Add static method getSoupRequestInitiaingPageID(). * platform/network/ResourceHandleInternal.h: (ResourceHandleInternal): Add initiatingPageID(). * platform/network/soup/ResourceHandleSoup.cpp: (WebCore::ResourceHandleInternal::initiatingPageID): Get the initiating page ID of the resource handle networking context. (WebCore::setSoupRequestInitiaingPageID): Helper function to attach a page ID to a SoupRequest. (WebCore::startHTTPRequest): Call setSoupRequestInitiaingPageID() to attch the initiating page ID to the SoupRequest. (WebCore::startNonHTTPRequest): Ditto. (WebCore::ResourceHandle::getSoupRequestInitiaingPageID): Static method to get the page ID attached to a SoupRequest. Source/WebKit/efl: * WebCoreSupport/FrameNetworkingContextEfl.cpp: (WebCore::FrameNetworkingContextEfl::initiatingPageID): Stub implementation. * WebCoreSupport/FrameNetworkingContextEfl.h: (FrameNetworkingContextEfl): Added. Source/WebKit/gtk: * WebCoreSupport/FrameNetworkingContextGtk.cpp: (WebKit::FrameNetworkingContextGtk::initiatingPageID): Stub implementation. * WebCoreSupport/FrameNetworkingContextGtk.h: (FrameNetworkingContextGtk): Added. Source/WebKit2: The message DidReceiveURIRequest is now sent to the page that initiated the request that forwards the mesassage to the WebSoupRequestManagerProxy. * UIProcess/API/C/soup/WKSoupRequestManager.h: Update didReceiveURIRequest callback to receive the initiating page ID. * UIProcess/API/efl/ewk_context_request_manager_client.cpp: (didReceiveURIRequest): Update the callback API change. * UIProcess/API/gtk/WebKitRequestManagerClient.cpp: (didReceiveURIRequest): Pass the initiating page to the WebKitURISchemeRequest constructor. * UIProcess/API/gtk/WebKitURISchemeRequest.cpp: (_WebKitURISchemeRequestPrivate): Keep a reference to the WebPageProxy that initiatesd the request. (webkitURISchemeRequestCreate): Save the initiating page. (webkit_uri_scheme_request_get_web_view): Return the view widget of the initiating WebPageProxy. * UIProcess/API/gtk/WebKitURISchemeRequest.h: * UIProcess/API/gtk/WebKitURISchemeRequestPrivate.h: * UIProcess/API/gtk/docs/webkit2gtk-sections.txt: Add new symbol. * UIProcess/API/gtk/tests/TestWebKitWebContext.cpp: * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::didReceiveURIRequest): Forward the request to the soup request manager proxy. * UIProcess/WebPageProxy.h: (WebPageProxy): Add didReceiveURIRequest(). * UIProcess/WebPageProxy.messages.in: Add DidReceiveURIRequest message. * UIProcess/soup/WebSoupRequestManagerClient.cpp: (WebKit::WebSoupRequestManagerClient::didReceiveURIRequest): Pass the inititing page to the client callback. * UIProcess/soup/WebSoupRequestManagerClient.h: (WebSoupRequestManagerClient): * UIProcess/soup/WebSoupRequestManagerProxy.cpp: (WebKit::WebSoupRequestManagerProxy::didReceiveURIRequest): Pass the inititing page to the client. * UIProcess/soup/WebSoupRequestManagerProxy.h: (WebSoupRequestManagerProxy): * UIProcess/soup/WebSoupRequestManagerProxy.messages.in: Remove DidReceiveURIRequest message. * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.cpp: (WebKit::WebFrameNetworkingContext::WebFrameNetworkingContext): Save the pageID of the WebFrame. (WebKit::WebFrameNetworkingContext::initiatingPageID): Return the inititing page ID. * WebProcess/WebCoreSupport/soup/WebFrameNetworkingContext.h: * WebProcess/soup/WebSoupRequestManager.cpp: (WebKit::WebSoupRequestManager::send): Send DidReceiveURIRequest message to the WebPage that initiated the request. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@130259 268f45cc-cd09-0410-ab3c-d52691b4dbfc
8cff89f2