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

Side by Side Diff: chrome/browser/profiles/profile_io_data.cc

Issue 2924163003: Remove socket performance watcher factory from URL request context builder (Closed)
Patch Set: ps Created 3 years, 6 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
« no previous file with comments | « no previous file | components/cronet/android/cronet_url_request_context_adapter.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/profiles/profile_io_data.h" 5 #include "chrome/browser/profiles/profile_io_data.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 1295 matching lines...) Expand 10 before | Expand all | Expand 10 after
1306 std::unique_ptr<net::HttpNetworkSession> 1306 std::unique_ptr<net::HttpNetworkSession>
1307 ProfileIOData::CreateHttpNetworkSession( 1307 ProfileIOData::CreateHttpNetworkSession(
1308 const ProfileParams& profile_params) const { 1308 const ProfileParams& profile_params) const {
1309 net::URLRequestContext* context = main_request_context(); 1309 net::URLRequestContext* context = main_request_context();
1310 1310
1311 IOThread* const io_thread = profile_params.io_thread; 1311 IOThread* const io_thread = profile_params.io_thread;
1312 1312
1313 net::HttpNetworkSession::Context session_context; 1313 net::HttpNetworkSession::Context session_context;
1314 net::URLRequestContextBuilder::SetHttpNetworkSessionComponents( 1314 net::URLRequestContextBuilder::SetHttpNetworkSessionComponents(
1315 context, &session_context); 1315 context, &session_context);
1316 if (!IsOffTheRecord()) {
1317 session_context.socket_performance_watcher_factory =
1318 io_thread->globals()
1319 ->network_quality_estimator->GetSocketPerformanceWatcherFactory();
1320 }
1321 if (data_reduction_proxy_io_data_.get()) { 1316 if (data_reduction_proxy_io_data_.get()) {
1322 session_context.proxy_delegate = 1317 session_context.proxy_delegate =
1323 data_reduction_proxy_io_data_->proxy_delegate(); 1318 data_reduction_proxy_io_data_->proxy_delegate();
1324 } 1319 }
1325 1320
1326 return std::unique_ptr<net::HttpNetworkSession>(new net::HttpNetworkSession( 1321 return std::unique_ptr<net::HttpNetworkSession>(new net::HttpNetworkSession(
1327 io_thread->NetworkSessionParams(), session_context)); 1322 io_thread->NetworkSessionParams(), session_context));
1328 } 1323 }
1329 1324
1330 std::unique_ptr<net::HttpCache> ProfileIOData::CreateMainHttpFactory( 1325 std::unique_ptr<net::HttpCache> ProfileIOData::CreateMainHttpFactory(
(...skipping 26 matching lines...) Expand all
1357 void ProfileIOData::SetCookieSettingsForTesting( 1352 void ProfileIOData::SetCookieSettingsForTesting(
1358 content_settings::CookieSettings* cookie_settings) { 1353 content_settings::CookieSettings* cookie_settings) {
1359 DCHECK(!cookie_settings_.get()); 1354 DCHECK(!cookie_settings_.get());
1360 cookie_settings_ = cookie_settings; 1355 cookie_settings_ = cookie_settings;
1361 } 1356 }
1362 1357
1363 policy::URLBlacklist::URLBlacklistState ProfileIOData::GetURLBlacklistState( 1358 policy::URLBlacklist::URLBlacklistState ProfileIOData::GetURLBlacklistState(
1364 const GURL& url) const { 1359 const GURL& url) const {
1365 return url_blacklist_manager_->GetURLBlacklistState(url); 1360 return url_blacklist_manager_->GetURLBlacklistState(url);
1366 } 1361 }
OLDNEW
« no previous file with comments | « no previous file | components/cronet/android/cronet_url_request_context_adapter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698