| 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_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 375 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 386 #if BUILDFLAG(ENABLE_EXTENSIONS) | 386 #if BUILDFLAG(ENABLE_EXTENSIONS) |
| 387 params->extension_info_map = | 387 params->extension_info_map = |
| 388 extensions::ExtensionSystem::Get(profile)->info_map(); | 388 extensions::ExtensionSystem::Get(profile)->info_map(); |
| 389 params->cookie_monster_delegate = new ExtensionCookieMonsterDelegate(profile); | 389 params->cookie_monster_delegate = new ExtensionCookieMonsterDelegate(profile); |
| 390 #endif | 390 #endif |
| 391 | 391 |
| 392 if (auto* loading_predictor = | 392 if (auto* loading_predictor = |
| 393 predictors::LoadingPredictorFactory::GetForProfile(profile)) { | 393 predictors::LoadingPredictorFactory::GetForProfile(profile)) { |
| 394 resource_prefetch_predictor_observer_.reset( | 394 resource_prefetch_predictor_observer_.reset( |
| 395 new chrome_browser_net::ResourcePrefetchPredictorObserver( | 395 new chrome_browser_net::ResourcePrefetchPredictorObserver( |
| 396 loading_predictor->resource_prefetch_predictor())); | 396 loading_predictor->loading_data_collector())); |
| 397 resource_prefetch_predictor_observer_ = |
| 398 base::MakeUnique<chrome_browser_net::ResourcePrefetchPredictorObserver>( |
| 399 loading_predictor->loading_data_collector()); |
| 397 } | 400 } |
| 398 | 401 |
| 399 ProtocolHandlerRegistry* protocol_handler_registry = | 402 ProtocolHandlerRegistry* protocol_handler_registry = |
| 400 ProtocolHandlerRegistryFactory::GetForBrowserContext(profile); | 403 ProtocolHandlerRegistryFactory::GetForBrowserContext(profile); |
| 401 DCHECK(protocol_handler_registry); | 404 DCHECK(protocol_handler_registry); |
| 402 | 405 |
| 403 // The profile instance is only available here in the InitializeOnUIThread | 406 // The profile instance is only available here in the InitializeOnUIThread |
| 404 // method, so we create the url job factory here, then save it for | 407 // method, so we create the url job factory here, then save it for |
| 405 // later delivery to the job factory in Init(). | 408 // later delivery to the job factory in Init(). |
| 406 params->protocol_handler_interceptor = | 409 params->protocol_handler_interceptor = |
| (...skipping 919 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1326 void ProfileIOData::SetCookieSettingsForTesting( | 1329 void ProfileIOData::SetCookieSettingsForTesting( |
| 1327 content_settings::CookieSettings* cookie_settings) { | 1330 content_settings::CookieSettings* cookie_settings) { |
| 1328 DCHECK(!cookie_settings_.get()); | 1331 DCHECK(!cookie_settings_.get()); |
| 1329 cookie_settings_ = cookie_settings; | 1332 cookie_settings_ = cookie_settings; |
| 1330 } | 1333 } |
| 1331 | 1334 |
| 1332 policy::URLBlacklist::URLBlacklistState ProfileIOData::GetURLBlacklistState( | 1335 policy::URLBlacklist::URLBlacklistState ProfileIOData::GetURLBlacklistState( |
| 1333 const GURL& url) const { | 1336 const GURL& url) const { |
| 1334 return url_blacklist_manager_->GetURLBlacklistState(url); | 1337 return url_blacklist_manager_->GetURLBlacklistState(url); |
| 1335 } | 1338 } |
| OLD | NEW |