Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(118)

Unified Diff: webkit/glue/webframeloaderclient_impl.cc

Issue 113836: DevTools: introduce bound object on the agent side. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/glue/webframeloaderclient_impl.h ('k') | webkit/glue/webview_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/webframeloaderclient_impl.cc
===================================================================
--- webkit/glue/webframeloaderclient_impl.cc (revision 16977)
+++ webkit/glue/webframeloaderclient_impl.cc (working copy)
@@ -46,7 +46,6 @@
#endif
#include "webkit/glue/autofill_form.h"
#include "webkit/glue/alt_404_page_resource_fetcher.h"
-#include "webkit/glue/devtools/net_agent_impl.h"
#include "webkit/glue/glue_util.h"
#include "webkit/glue/password_form_dom_manager.h"
#include "webkit/glue/plugins/plugin_list.h"
@@ -181,10 +180,6 @@
WebRequestImpl webreq(request);
d->AssignIdentifierToRequest(webview, identifier, webreq);
}
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->AssignIdentifierToRequest(loader, identifier, request);
- }
}
// Determines whether the request being loaded by |loader| is a frame or a
@@ -233,10 +228,6 @@
d->WillSendRequest(webview, identifier, &webreq);
request = webreq.resource_request();
}
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->WillSendRequest(loader, identifier, request);
- }
request.setAppCacheContextID(
webframe_->GetAppCacheContext()->GetContextID());
@@ -304,21 +295,12 @@
// Cancel any pending loads.
alt_404_page_fetcher_.reset(NULL);
-
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->DidReceiveResponse(loader, identifier, response);
- }
}
void WebFrameLoaderClient::dispatchDidReceiveContentLength(
DocumentLoader* loader,
unsigned long identifier,
int length_received) {
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->DidReceiveContentLength(loader, identifier, length_received);
- }
}
// Called when a particular resource load completes
@@ -338,11 +320,6 @@
WebViewDelegate* d = webview->delegate();
if (d)
d->DidFinishLoading(webview, identifier);
-
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->DidFinishLoading(loader, identifier);
- }
}
GURL WebFrameLoaderClient::GetAlt404PageUrl(DocumentLoader* loader) {
@@ -384,10 +361,6 @@
webview->delegate()->DidFailLoadingWithError(webview, identifier,
WebErrorImpl(error));
}
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->DidFailLoading(loader, identifier, error);
- }
}
void WebFrameLoaderClient::dispatchDidFinishDocumentLoad() {
@@ -451,26 +424,12 @@
result = d->DidLoadResourceFromMemoryCache(webview, webreq, webresp,
webframe_);
}
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->DidLoadResourceFromMemoryCache(
- loader,
- request,
- response,
- length);
- }
return result;
}
void WebFrameLoaderClient::dispatchDidLoadResourceByXMLHttpRequest(
unsigned long identifier,
const ScriptString& source) {
- NetAgentImpl* net_agent = GetNetAgentImpl();
- if (net_agent) {
- net_agent->DidLoadResourceByXMLHttpRequest(
- identifier,
- source);
- }
}
void WebFrameLoaderClient::dispatchDidHandleOnloadEvents() {
@@ -1643,16 +1602,3 @@
if (d)
d->NavigateBackForwardSoon(offset);
}
-
-NetAgentImpl* WebFrameLoaderClient::GetNetAgentImpl() {
- WebViewImpl* web_view = webframe_->GetWebViewImpl();
- if (!web_view) {
- return NULL;
- }
- WebDevToolsAgentImpl* tools_agent = web_view->GetWebDevToolsAgentImpl();
- if (tools_agent) {
- return tools_agent->net_agent_impl();
- } else {
- return NULL;
- }
-}
« no previous file with comments | « webkit/glue/webframeloaderclient_impl.h ('k') | webkit/glue/webview_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698