Index: content/browser/web_contents/web_contents_impl.cc |
diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc |
index 2d3c542c58a29808e9a7f2b8257bf6608a935459..a51ec8cd37c102d2114188fc3bb95c4729e80ca7 100644 |
--- a/content/browser/web_contents/web_contents_impl.cc |
+++ b/content/browser/web_contents/web_contents_impl.cc |
@@ -2179,8 +2179,8 @@ void WebContentsImpl::DidRedirectProvisionalLoad( |
const GURL& source_url, |
const GURL& target_url) { |
// TODO(creis): Remove this method and have the pre-rendering code listen to |
- // the ResourceDispatcherHost's RESOURCE_RECEIVED_REDIRECT notification |
- // instead. See http://crbug.com/78512. |
+ // WebContentsObserver::DidGetRedirectForResourceRequest instead. |
+ // See http://crbug.com/78512. |
GURL validated_source_url(source_url); |
GURL validated_target_url(target_url); |
RenderProcessHost* render_process_host = |
@@ -2279,6 +2279,12 @@ void WebContentsImpl::OnDidLoadResourceFromMemoryCache( |
url, GetRenderProcessHost()->GetID(), cert_id, cert_status, http_method, |
mime_type, resource_type); |
+ controller_.ssl_manager()->DidLoadFromMemoryCache(details); |
+ |
+ FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
+ DidLoadResourceFromMemoryCache(details)); |
+ |
+ // TODO(avi): Remove. http://crbug.com/170921 |
NotificationService::current()->Notify( |
NOTIFICATION_LOAD_FROM_MEMORY_CACHE, |
Source<NavigationController>(&controller_), |
@@ -2939,6 +2945,34 @@ void WebContentsImpl::RenderViewDeleted(RenderViewHost* rvh) { |
FOR_EACH_OBSERVER(WebContentsObserver, observers_, RenderViewDeleted(rvh)); |
} |
+void WebContentsImpl::DidGetResourceResponseStart( |
+ const ResourceRequestDetails& details) { |
+ controller_.ssl_manager()->DidStartResourceResponse(details); |
+ |
+ FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
+ DidGetResourceResponseStart(details)); |
+ |
+ // TODO(avi): Remove. http://crbug.com/170921 |
+ NotificationService::current()->Notify( |
+ NOTIFICATION_RESOURCE_RESPONSE_STARTED, |
+ Source<WebContents>(this), |
+ Details<const ResourceRequestDetails>(&details)); |
+} |
+ |
+void WebContentsImpl::DidGetRedirectForResourceRequest( |
+ const ResourceRedirectDetails& details) { |
+ controller_.ssl_manager()->DidReceiveResourceRedirect(details); |
+ |
+ FOR_EACH_OBSERVER(WebContentsObserver, observers_, |
+ DidGetRedirectForResourceRequest(details)); |
+ |
+ // TODO(avi): Remove. http://crbug.com/170921 |
+ NotificationService::current()->Notify( |
+ NOTIFICATION_RESOURCE_RECEIVED_REDIRECT, |
+ Source<WebContents>(this), |
+ Details<const ResourceRedirectDetails>(&details)); |
+} |
+ |
void WebContentsImpl::DidNavigate( |
RenderViewHost* rvh, |
const ViewHostMsg_FrameNavigate_Params& params) { |