Chromium Code Reviews| OLD | NEW |
|---|---|
| 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_impl_io_data.h" | 5 #include "chrome/browser/profiles/profile_impl_io_data.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/metrics/field_trial.h" | 10 #include "base/metrics/field_trial.h" |
| (...skipping 13 matching lines...) Expand all Loading... | |
| 24 #include "chrome/browser/net/chrome_network_delegate.h" | 24 #include "chrome/browser/net/chrome_network_delegate.h" |
| 25 #include "chrome/browser/net/connect_interceptor.h" | 25 #include "chrome/browser/net/connect_interceptor.h" |
| 26 #include "chrome/browser/net/cookie_store_util.h" | 26 #include "chrome/browser/net/cookie_store_util.h" |
| 27 #include "chrome/browser/net/http_server_properties_manager_factory.h" | 27 #include "chrome/browser/net/http_server_properties_manager_factory.h" |
| 28 #include "chrome/browser/net/predictor.h" | 28 #include "chrome/browser/net/predictor.h" |
| 29 #include "chrome/browser/net/quota_policy_channel_id_store.h" | 29 #include "chrome/browser/net/quota_policy_channel_id_store.h" |
| 30 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_configurator. h" | 30 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_configurator. h" |
| 31 #include "chrome/browser/profiles/profile.h" | 31 #include "chrome/browser/profiles/profile.h" |
| 32 #include "chrome/common/chrome_constants.h" | 32 #include "chrome/common/chrome_constants.h" |
| 33 #include "chrome/common/chrome_switches.h" | 33 #include "chrome/common/chrome_switches.h" |
| 34 #include "chrome/common/chrome_version_info.h" | |
| 34 #include "chrome/common/pref_names.h" | 35 #include "chrome/common/pref_names.h" |
| 35 #include "chrome/common/url_constants.h" | 36 #include "chrome/common/url_constants.h" |
| 36 #include "components/domain_reliability/monitor.h" | 37 #include "components/domain_reliability/monitor.h" |
| 37 #include "content/public/browser/browser_thread.h" | 38 #include "content/public/browser/browser_thread.h" |
| 38 #include "content/public/browser/cookie_store_factory.h" | 39 #include "content/public/browser/cookie_store_factory.h" |
| 39 #include "content/public/browser/notification_service.h" | 40 #include "content/public/browser/notification_service.h" |
| 40 #include "content/public/browser/resource_context.h" | 41 #include "content/public/browser/resource_context.h" |
| 41 #include "content/public/browser/storage_partition.h" | 42 #include "content/public/browser/storage_partition.h" |
| 42 #include "extensions/browser/extension_protocols.h" | 43 #include "extensions/browser/extension_protocols.h" |
| 43 #include "extensions/common/constants.h" | 44 #include "extensions/common/constants.h" |
| (...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 423 void ProfileImplIOData::InitializeInternal( | 424 void ProfileImplIOData::InitializeInternal( |
| 424 ProfileParams* profile_params, | 425 ProfileParams* profile_params, |
| 425 content::ProtocolHandlerMap* protocol_handlers, | 426 content::ProtocolHandlerMap* protocol_handlers, |
| 426 content::URLRequestInterceptorScopedVector request_interceptors) const { | 427 content::URLRequestInterceptorScopedVector request_interceptors) const { |
| 427 net::URLRequestContext* main_context = main_request_context(); | 428 net::URLRequestContext* main_context = main_request_context(); |
| 428 | 429 |
| 429 IOThread* const io_thread = profile_params->io_thread; | 430 IOThread* const io_thread = profile_params->io_thread; |
| 430 IOThread::Globals* const io_thread_globals = io_thread->globals(); | 431 IOThread::Globals* const io_thread_globals = io_thread->globals(); |
| 431 | 432 |
| 432 #if defined(SPDY_PROXY_AUTH_ORIGIN) | 433 #if defined(SPDY_PROXY_AUTH_ORIGIN) |
| 434 chrome::VersionInfo version_info; | |
| 433 data_reduction_proxy_auth_request_handler_.reset( | 435 data_reduction_proxy_auth_request_handler_.reset( |
| 434 new data_reduction_proxy::DataReductionProxyAuthRequestHandler( | 436 new data_reduction_proxy::DataReductionProxyAuthRequestHandler( |
| 435 DataReductionProxyChromeSettings::GetClient(), | 437 DataReductionProxyChromeSettings::GetClient(), |
| 436 DataReductionProxyChromeSettings::GetBuildAndPatchNumber(), | 438 version_info.Version(), |
|
mmenke
2014/09/04 19:12:10
Per comment in other file, you don't need the loca
megjablon
2014/09/04 19:16:36
Done.
| |
| 437 data_reduction_proxy_params_.get(), | 439 data_reduction_proxy_params_.get(), |
| 438 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO))); | 440 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO))); |
| 439 data_reduction_proxy_usage_stats_.reset( | 441 data_reduction_proxy_usage_stats_.reset( |
| 440 new data_reduction_proxy::DataReductionProxyUsageStats( | 442 new data_reduction_proxy::DataReductionProxyUsageStats( |
| 441 data_reduction_proxy_params_.get(), | 443 data_reduction_proxy_params_.get(), |
| 442 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI))); | 444 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI))); |
| 443 data_reduction_proxy_usage_stats_->set_unavailable_callback( | 445 data_reduction_proxy_usage_stats_->set_unavailable_callback( |
| 444 data_reduction_proxy_unavailable_callback_); | 446 data_reduction_proxy_unavailable_callback_); |
| 445 | 447 |
| 446 | 448 |
| (...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 835 const base::Closure& completion) { | 837 const base::Closure& completion) { |
| 836 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); | 838 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
| 837 DCHECK(initialized()); | 839 DCHECK(initialized()); |
| 838 | 840 |
| 839 DCHECK(transport_security_state()); | 841 DCHECK(transport_security_state()); |
| 840 // Completes synchronously. | 842 // Completes synchronously. |
| 841 transport_security_state()->DeleteAllDynamicDataSince(time); | 843 transport_security_state()->DeleteAllDynamicDataSince(time); |
| 842 DCHECK(http_server_properties_manager_); | 844 DCHECK(http_server_properties_manager_); |
| 843 http_server_properties_manager_->Clear(completion); | 845 http_server_properties_manager_->Clear(completion); |
| 844 } | 846 } |
| OLD | NEW |