| 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 <memory> | 7 #include <memory> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 #include "base/threading/worker_pool.h" | 21 #include "base/threading/worker_pool.h" |
| 22 #include "build/build_config.h" | 22 #include "build/build_config.h" |
| 23 #include "chrome/browser/browser_process.h" | 23 #include "chrome/browser/browser_process.h" |
| 24 #include "chrome/browser/chrome_notification_types.h" | 24 #include "chrome/browser/chrome_notification_types.h" |
| 25 #include "chrome/browser/chromeos/profiles/profile_helper.h" | 25 #include "chrome/browser/chromeos/profiles/profile_helper.h" |
| 26 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" | 26 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" |
| 27 #include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h" | 27 #include "chrome/browser/custom_handlers/protocol_handler_registry_factory.h" |
| 28 #include "chrome/browser/io_thread.h" | 28 #include "chrome/browser/io_thread.h" |
| 29 #include "chrome/browser/net/chrome_network_delegate.h" | 29 #include "chrome/browser/net/chrome_network_delegate.h" |
| 30 #include "chrome/browser/net/http_server_properties_manager_factory.h" | 30 #include "chrome/browser/net/http_server_properties_manager_factory.h" |
| 31 #include "chrome/browser/net/nqe/ui_network_quality_estimator_service.h" |
| 32 #include "chrome/browser/net/nqe/ui_network_quality_estimator_service_factory.h" |
| 31 #include "chrome/browser/net/predictor.h" | 33 #include "chrome/browser/net/predictor.h" |
| 32 #include "chrome/browser/net/quota_policy_channel_id_store.h" | 34 #include "chrome/browser/net/quota_policy_channel_id_store.h" |
| 33 #include "chrome/browser/net/sdch_owner_pref_storage.h" | 35 #include "chrome/browser/net/sdch_owner_pref_storage.h" |
| 34 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_io_data.h" | 36 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_io_data.h" |
| 35 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings.h" | 37 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings.h" |
| 36 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings_fact
ory.h" | 38 #include "chrome/browser/net/spdyproxy/data_reduction_proxy_chrome_settings_fact
ory.h" |
| 37 #include "chrome/browser/profiles/profile.h" | 39 #include "chrome/browser/profiles/profile.h" |
| 38 #include "chrome/common/chrome_constants.h" | 40 #include "chrome/common/chrome_constants.h" |
| 39 #include "chrome/common/chrome_switches.h" | 41 #include "chrome/common/chrome_switches.h" |
| 40 #include "chrome/common/pref_names.h" | 42 #include "chrome/common/pref_names.h" |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 196 pool->GetSequenceToken(), | 198 pool->GetSequenceToken(), |
| 197 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN); | 199 base::SequencedWorkerPool::SKIP_ON_SHUTDOWN); |
| 198 std::unique_ptr<data_reduction_proxy::DataStore> store( | 200 std::unique_ptr<data_reduction_proxy::DataStore> store( |
| 199 new data_reduction_proxy::DataStoreImpl(profile_path)); | 201 new data_reduction_proxy::DataStoreImpl(profile_path)); |
| 200 DataReductionProxyChromeSettingsFactory::GetForBrowserContext(profile_) | 202 DataReductionProxyChromeSettingsFactory::GetForBrowserContext(profile_) |
| 201 ->InitDataReductionProxySettings( | 203 ->InitDataReductionProxySettings( |
| 202 io_data_->data_reduction_proxy_io_data(), profile_->GetPrefs(), | 204 io_data_->data_reduction_proxy_io_data(), profile_->GetPrefs(), |
| 203 profile_->GetRequestContext(), std::move(store), | 205 profile_->GetRequestContext(), std::move(store), |
| 204 BrowserThread::GetTaskRunnerForThread(BrowserThread::UI), | 206 BrowserThread::GetTaskRunnerForThread(BrowserThread::UI), |
| 205 db_task_runner); | 207 db_task_runner); |
| 208 chrome_browser_net::UINetworkQualityEstimatorServiceFactory::GetForProfile( |
| 209 profile_) |
| 210 ->Initialize(BrowserThread::GetTaskRunnerForThread(BrowserThread::UI), |
| 211 BrowserThread::GetTaskRunnerForThread(BrowserThread::IO)); |
| 206 } | 212 } |
| 207 | 213 |
| 208 content::ResourceContext* | 214 content::ResourceContext* |
| 209 ProfileImplIOData::Handle::GetResourceContext() const { | 215 ProfileImplIOData::Handle::GetResourceContext() const { |
| 210 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 216 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 211 LazyInitialize(); | 217 LazyInitialize(); |
| 212 return GetResourceContextNoInit(); | 218 return GetResourceContextNoInit(); |
| 213 } | 219 } |
| 214 | 220 |
| 215 content::ResourceContext* | 221 content::ResourceContext* |
| (...skipping 576 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 792 const base::Closure& completion) { | 798 const base::Closure& completion) { |
| 793 DCHECK_CURRENTLY_ON(BrowserThread::IO); | 799 DCHECK_CURRENTLY_ON(BrowserThread::IO); |
| 794 DCHECK(initialized()); | 800 DCHECK(initialized()); |
| 795 | 801 |
| 796 DCHECK(transport_security_state()); | 802 DCHECK(transport_security_state()); |
| 797 // Completes synchronously. | 803 // Completes synchronously. |
| 798 transport_security_state()->DeleteAllDynamicDataSince(time); | 804 transport_security_state()->DeleteAllDynamicDataSince(time); |
| 799 DCHECK(http_server_properties_manager_); | 805 DCHECK(http_server_properties_manager_); |
| 800 http_server_properties_manager_->Clear(completion); | 806 http_server_properties_manager_->Clear(completion); |
| 801 } | 807 } |
| OLD | NEW |