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/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 #include "chrome/browser/browser_shutdown.h" | 43 #include "chrome/browser/browser_shutdown.h" |
44 #include "chrome/browser/chrome_browser_main_extra_parts.h" | 44 #include "chrome/browser/chrome_browser_main_extra_parts.h" |
45 #include "chrome/browser/component_updater/cld_component_installer.h" | 45 #include "chrome/browser/component_updater/cld_component_installer.h" |
46 #include "chrome/browser/component_updater/component_updater_service.h" | 46 #include "chrome/browser/component_updater/component_updater_service.h" |
47 #include "chrome/browser/component_updater/flash_component_installer.h" | 47 #include "chrome/browser/component_updater/flash_component_installer.h" |
48 #include "chrome/browser/component_updater/pnacl/pnacl_component_installer.h" | 48 #include "chrome/browser/component_updater/pnacl/pnacl_component_installer.h" |
49 #include "chrome/browser/component_updater/recovery_component_installer.h" | 49 #include "chrome/browser/component_updater/recovery_component_installer.h" |
50 #include "chrome/browser/component_updater/swiftshader_component_installer.h" | 50 #include "chrome/browser/component_updater/swiftshader_component_installer.h" |
51 #include "chrome/browser/component_updater/widevine_cdm_component_installer.h" | 51 #include "chrome/browser/component_updater/widevine_cdm_component_installer.h" |
52 #include "chrome/browser/defaults.h" | 52 #include "chrome/browser/defaults.h" |
| 53 #include "chrome/browser/devtools/devtools_window.h" |
53 #include "chrome/browser/extensions/extension_service.h" | 54 #include "chrome/browser/extensions/extension_service.h" |
54 #include "chrome/browser/extensions/startup_helper.h" | 55 #include "chrome/browser/extensions/startup_helper.h" |
55 #include "chrome/browser/feedback/feedback_profile_observer.h" | 56 #include "chrome/browser/feedback/feedback_profile_observer.h" |
56 #include "chrome/browser/first_run/first_run.h" | 57 #include "chrome/browser/first_run/first_run.h" |
57 #include "chrome/browser/first_run/upgrade_util.h" | 58 #include "chrome/browser/first_run/upgrade_util.h" |
58 #include "chrome/browser/google/google_search_counter.h" | 59 #include "chrome/browser/google/google_search_counter.h" |
59 #include "chrome/browser/google/google_util.h" | 60 #include "chrome/browser/google/google_util.h" |
60 #include "chrome/browser/gpu/gl_string_manager.h" | 61 #include "chrome/browser/gpu/gl_string_manager.h" |
61 #include "chrome/browser/jankometer.h" | 62 #include "chrome/browser/jankometer.h" |
62 #include "chrome/browser/media/media_capture_devices_dispatcher.h" | 63 #include "chrome/browser/media/media_capture_devices_dispatcher.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
109 #include "chrome/common/profiling.h" | 110 #include "chrome/common/profiling.h" |
110 #include "chrome/installer/util/google_update_settings.h" | 111 #include "chrome/installer/util/google_update_settings.h" |
111 #include "components/language_usage_metrics/language_usage_metrics.h" | 112 #include "components/language_usage_metrics/language_usage_metrics.h" |
112 #include "components/nacl/browser/nacl_browser.h" | 113 #include "components/nacl/browser/nacl_browser.h" |
113 #include "components/nacl/browser/nacl_process_host.h" | 114 #include "components/nacl/browser/nacl_process_host.h" |
114 #include "components/rappor/rappor_service.h" | 115 #include "components/rappor/rappor_service.h" |
115 #include "components/signin/core/common/profile_management_switches.h" | 116 #include "components/signin/core/common/profile_management_switches.h" |
116 #include "components/startup_metric_utils/startup_metric_utils.h" | 117 #include "components/startup_metric_utils/startup_metric_utils.h" |
117 #include "components/translate/core/browser/translate_download_manager.h" | 118 #include "components/translate/core/browser/translate_download_manager.h" |
118 #include "content/public/browser/browser_thread.h" | 119 #include "content/public/browser/browser_thread.h" |
| 120 #include "content/public/browser/devtools_manager.h" |
119 #include "content/public/browser/notification_observer.h" | 121 #include "content/public/browser/notification_observer.h" |
120 #include "content/public/browser/notification_registrar.h" | 122 #include "content/public/browser/notification_registrar.h" |
121 #include "content/public/browser/notification_service.h" | 123 #include "content/public/browser/notification_service.h" |
122 #include "content/public/browser/notification_types.h" | 124 #include "content/public/browser/notification_types.h" |
123 #include "content/public/browser/site_instance.h" | 125 #include "content/public/browser/site_instance.h" |
124 #include "content/public/common/content_client.h" | 126 #include "content/public/common/content_client.h" |
125 #include "content/public/common/content_switches.h" | 127 #include "content/public/common/content_switches.h" |
126 #include "content/public/common/main_function_params.h" | 128 #include "content/public/common/main_function_params.h" |
127 #include "extensions/browser/extension_protocols.h" | 129 #include "extensions/browser/extension_protocols.h" |
128 #include "extensions/browser/extension_system.h" | 130 #include "extensions/browser/extension_system.h" |
(...skipping 1117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1246 #endif | 1248 #endif |
1247 // Post-profile init --------------------------------------------------------- | 1249 // Post-profile init --------------------------------------------------------- |
1248 | 1250 |
1249 TranslateService::Initialize(); | 1251 TranslateService::Initialize(); |
1250 | 1252 |
1251 // Needs to be done before PostProfileInit, since login manager on CrOS is | 1253 // Needs to be done before PostProfileInit, since login manager on CrOS is |
1252 // called inside PostProfileInit. | 1254 // called inside PostProfileInit. |
1253 content::WebUIControllerFactory::RegisterFactory( | 1255 content::WebUIControllerFactory::RegisterFactory( |
1254 ChromeWebUIControllerFactory::GetInstance()); | 1256 ChromeWebUIControllerFactory::GetInstance()); |
1255 | 1257 |
1256 // NaClBrowserDelegateImpl is accessed inside PostProfileInit(). | 1258 content::DevToolsManager::GetInstance() |
1257 // So make sure to create it before that. | 1259 ->RegisterOpenDevToolsWindowForWorkerCallback( |
| 1260 DevToolsWindow::GetOpenDevToolsWindowForWorkerCallback()); |
| 1261 |
| 1262 // NaClBrowserDelegateImpl is accessed inside PostProfileInit(). |
| 1263 // So make sure to create it before that. |
1258 #if !defined(DISABLE_NACL) | 1264 #if !defined(DISABLE_NACL) |
1259 NaClBrowserDelegateImpl* delegate = new NaClBrowserDelegateImpl( | 1265 NaClBrowserDelegateImpl* delegate = new NaClBrowserDelegateImpl( |
1260 extensions::ExtensionSystem::Get(profile_)->info_map()); | 1266 extensions::ExtensionSystem::Get(profile_)->info_map()); |
1261 nacl::NaClBrowser::SetDelegate(delegate); | 1267 nacl::NaClBrowser::SetDelegate(delegate); |
1262 #endif | 1268 #endif |
1263 | 1269 |
1264 // TODO(stevenjb): Move WIN and MACOSX specific code to appropriate Parts. | 1270 // TODO(stevenjb): Move WIN and MACOSX specific code to appropriate Parts. |
1265 // (requires supporting early exit). | 1271 // (requires supporting early exit). |
1266 PostProfileInit(); | 1272 PostProfileInit(); |
1267 | 1273 |
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1653 chromeos::CrosSettings::Shutdown(); | 1659 chromeos::CrosSettings::Shutdown(); |
1654 #endif | 1660 #endif |
1655 #endif | 1661 #endif |
1656 } | 1662 } |
1657 | 1663 |
1658 // Public members: | 1664 // Public members: |
1659 | 1665 |
1660 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1666 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
1661 chrome_extra_parts_.push_back(parts); | 1667 chrome_extra_parts_.push_back(parts); |
1662 } | 1668 } |
OLD | NEW |