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 <string> | 7 #include <string> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
11 #include "base/bind_helpers.h" | 11 #include "base/bind_helpers.h" |
12 #include "base/command_line.h" | 12 #include "base/command_line.h" |
13 #include "base/compiler_specific.h" | 13 #include "base/compiler_specific.h" |
14 #include "base/logging.h" | 14 #include "base/logging.h" |
15 #include "base/stl_util.h" | 15 #include "base/stl_util.h" |
16 #include "base/string_number_conversions.h" | 16 #include "base/string_number_conversions.h" |
17 #include "base/string_util.h" | 17 #include "base/string_util.h" |
18 #include "chrome/browser/browser_process.h" | 18 #include "chrome/browser/browser_process.h" |
19 #include "chrome/browser/content_settings/cookie_settings.h" | 19 #include "chrome/browser/content_settings/cookie_settings.h" |
20 #include "chrome/browser/content_settings/host_content_settings_map.h" | 20 #include "chrome/browser/content_settings/host_content_settings_map.h" |
21 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" | 21 #include "chrome/browser/custom_handlers/protocol_handler_registry.h" |
22 #include "chrome/browser/download/download_service.h" | 22 #include "chrome/browser/download/download_service.h" |
23 #include "chrome/browser/download/download_service_factory.h" | 23 #include "chrome/browser/download/download_service_factory.h" |
24 #include "chrome/browser/extensions/extension_info_map.h" | 24 #include "chrome/browser/extensions/extension_info_map.h" |
25 #include "chrome/browser/extensions/extension_protocols.h" | 25 #include "chrome/browser/extensions/extension_protocols.h" |
| 26 #include "chrome/browser/extensions/extension_system.h" |
| 27 #include "chrome/browser/extensions/extension_system_factory.h" |
26 #include "chrome/browser/io_thread.h" | 28 #include "chrome/browser/io_thread.h" |
27 #include "chrome/browser/media/media_internals.h" | 29 #include "chrome/browser/media/media_internals.h" |
28 #include "chrome/browser/net/chrome_cookie_notification_details.h" | 30 #include "chrome/browser/net/chrome_cookie_notification_details.h" |
29 #include "chrome/browser/net/chrome_fraudulent_certificate_reporter.h" | 31 #include "chrome/browser/net/chrome_fraudulent_certificate_reporter.h" |
30 #include "chrome/browser/net/chrome_net_log.h" | 32 #include "chrome/browser/net/chrome_net_log.h" |
31 #include "chrome/browser/net/chrome_network_delegate.h" | 33 #include "chrome/browser/net/chrome_network_delegate.h" |
32 #include "chrome/browser/net/proxy_service_factory.h" | 34 #include "chrome/browser/net/proxy_service_factory.h" |
33 #include "chrome/browser/notifications/desktop_notification_service_factory.h" | 35 #include "chrome/browser/notifications/desktop_notification_service_factory.h" |
34 #include "chrome/browser/policy/url_blacklist_manager.h" | 36 #include "chrome/browser/policy/url_blacklist_manager.h" |
35 #include "chrome/browser/prefs/pref_service.h" | 37 #include "chrome/browser/prefs/pref_service.h" |
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 params->io_thread = g_browser_process->io_thread(); | 217 params->io_thread = g_browser_process->io_thread(); |
216 | 218 |
217 params->host_content_settings_map = profile->GetHostContentSettingsMap(); | 219 params->host_content_settings_map = profile->GetHostContentSettingsMap(); |
218 params->cookie_settings = CookieSettings::Factory::GetForProfile(profile); | 220 params->cookie_settings = CookieSettings::Factory::GetForProfile(profile); |
219 params->ssl_config_service = profile->GetSSLConfigService(); | 221 params->ssl_config_service = profile->GetSSLConfigService(); |
220 base::Callback<Profile*(void)> profile_getter = | 222 base::Callback<Profile*(void)> profile_getter = |
221 base::Bind(&GetProfileOnUI, g_browser_process->profile_manager(), | 223 base::Bind(&GetProfileOnUI, g_browser_process->profile_manager(), |
222 profile); | 224 profile); |
223 params->cookie_monster_delegate = | 225 params->cookie_monster_delegate = |
224 new ChromeCookieMonsterDelegate(profile_getter); | 226 new ChromeCookieMonsterDelegate(profile_getter); |
225 params->extension_info_map = profile->GetExtensionInfoMap(); | 227 params->extension_info_map = |
| 228 ExtensionSystemFactory::GetForProfile(profile)->info_map(); |
226 | 229 |
227 #if defined(ENABLE_NOTIFICATIONS) | 230 #if defined(ENABLE_NOTIFICATIONS) |
228 params->notification_service = | 231 params->notification_service = |
229 DesktopNotificationServiceFactory::GetForProfile(profile); | 232 DesktopNotificationServiceFactory::GetForProfile(profile); |
230 #endif | 233 #endif |
231 | 234 |
232 params->protocol_handler_registry = profile->GetProtocolHandlerRegistry(); | 235 params->protocol_handler_registry = profile->GetProtocolHandlerRegistry(); |
233 | 236 |
234 ChromeProxyConfigService* proxy_config_service = | 237 ChromeProxyConfigService* proxy_config_service = |
235 ProxyServiceFactory::CreateProxyConfigService(true); | 238 ProxyServiceFactory::CreateProxyConfigService(true); |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
558 &resource_context_)); | 561 &resource_context_)); |
559 bool posted = BrowserThread::DeleteSoon(BrowserThread::IO, FROM_HERE, this); | 562 bool posted = BrowserThread::DeleteSoon(BrowserThread::IO, FROM_HERE, this); |
560 if (!posted) | 563 if (!posted) |
561 delete this; | 564 delete this; |
562 } | 565 } |
563 | 566 |
564 void ProfileIOData::set_origin_bound_cert_service( | 567 void ProfileIOData::set_origin_bound_cert_service( |
565 net::OriginBoundCertService* origin_bound_cert_service) const { | 568 net::OriginBoundCertService* origin_bound_cert_service) const { |
566 origin_bound_cert_service_.reset(origin_bound_cert_service); | 569 origin_bound_cert_service_.reset(origin_bound_cert_service); |
567 } | 570 } |
OLD | NEW |