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

Side by Side Diff: content/browser/loader/navigation_url_loader_impl.cc

Issue 1811913003: PlzNavigate: support NavigationThrottle::WillProcessResponse (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase on top of 1832803002 Created 4 years, 9 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/loader/navigation_url_loader_impl.h" 5 #include "content/browser/loader/navigation_url_loader_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 55
56 void NavigationURLLoaderImpl::FollowRedirect() { 56 void NavigationURLLoaderImpl::FollowRedirect() {
57 DCHECK_CURRENTLY_ON(BrowserThread::UI); 57 DCHECK_CURRENTLY_ON(BrowserThread::UI);
58 58
59 BrowserThread::PostTask( 59 BrowserThread::PostTask(
60 BrowserThread::IO, FROM_HERE, 60 BrowserThread::IO, FROM_HERE,
61 base::Bind(&NavigationURLLoaderImplCore::FollowRedirect, 61 base::Bind(&NavigationURLLoaderImplCore::FollowRedirect,
62 base::Unretained(core_))); 62 base::Unretained(core_)));
63 } 63 }
64 64
65 void NavigationURLLoaderImpl::ProceedWithResponse() {
66 DCHECK_CURRENTLY_ON(BrowserThread::UI);
67
68 BrowserThread::PostTask(
69 BrowserThread::IO, FROM_HERE,
70 base::Bind(&NavigationURLLoaderImplCore::ProceedWithResponse,
71 base::Unretained(core_)));
72 }
73
65 void NavigationURLLoaderImpl::NotifyRequestRedirected( 74 void NavigationURLLoaderImpl::NotifyRequestRedirected(
66 const net::RedirectInfo& redirect_info, 75 const net::RedirectInfo& redirect_info,
67 const scoped_refptr<ResourceResponse>& response) { 76 const scoped_refptr<ResourceResponse>& response) {
68 DCHECK_CURRENTLY_ON(BrowserThread::UI); 77 DCHECK_CURRENTLY_ON(BrowserThread::UI);
69 78
70 delegate_->OnRequestRedirected(redirect_info, response); 79 delegate_->OnRequestRedirected(redirect_info, response);
71 } 80 }
72 81
73 void NavigationURLLoaderImpl::NotifyResponseStarted( 82 void NavigationURLLoaderImpl::NotifyResponseStarted(
74 const scoped_refptr<ResourceResponse>& response, 83 const scoped_refptr<ResourceResponse>& response,
(...skipping 10 matching lines...) Expand all
85 delegate_->OnRequestFailed(in_cache, net_error); 94 delegate_->OnRequestFailed(in_cache, net_error);
86 } 95 }
87 96
88 void NavigationURLLoaderImpl::NotifyRequestStarted(base::TimeTicks timestamp) { 97 void NavigationURLLoaderImpl::NotifyRequestStarted(base::TimeTicks timestamp) {
89 DCHECK_CURRENTLY_ON(BrowserThread::UI); 98 DCHECK_CURRENTLY_ON(BrowserThread::UI);
90 99
91 delegate_->OnRequestStarted(timestamp); 100 delegate_->OnRequestStarted(timestamp);
92 } 101 }
93 102
94 } // namespace content 103 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/loader/navigation_url_loader_impl.h ('k') | content/browser/loader/navigation_url_loader_impl_core.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698