| 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 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 374 return NULL; | 374 return NULL; |
| 375 } | 375 } |
| 376 | 376 |
| 377 #if defined(OS_MACOSX) | 377 #if defined(OS_MACOSX) |
| 378 OSStatus KeychainCallback(SecKeychainEvent keychain_event, | 378 OSStatus KeychainCallback(SecKeychainEvent keychain_event, |
| 379 SecKeychainCallbackInfo* info, void* context) { | 379 SecKeychainCallbackInfo* info, void* context) { |
| 380 return noErr; | 380 return noErr; |
| 381 } | 381 } |
| 382 #endif | 382 #endif |
| 383 | 383 |
| 384 void RegisterComponentsForUpdate(const CommandLine& command_line) { | 384 void RegisterComponentsForUpdate() { |
| 385 component_updater::ComponentUpdateService* cus = | 385 component_updater::ComponentUpdateService* cus = |
| 386 g_browser_process->component_updater(); | 386 g_browser_process->component_updater(); |
| 387 | 387 |
| 388 // Registration can be before or after cus->Start() so it is ok to post | 388 // Registration can be before or after cus->Start() so it is ok to post |
| 389 // a task to the UI thread to do registration once you done the necessary | 389 // a task to the UI thread to do registration once you done the necessary |
| 390 // file IO to know you existing component version. | 390 // file IO to know you existing component version. |
| 391 #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) | 391 #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) |
| 392 RegisterRecoveryComponent(cus, g_browser_process->local_state()); | 392 RegisterRecoveryComponent(cus, g_browser_process->local_state()); |
| 393 RegisterPepperFlashComponent(cus); | 393 RegisterPepperFlashComponent(cus); |
| 394 RegisterSwiftShaderComponent(cus); | 394 RegisterSwiftShaderComponent(cus); |
| 395 g_browser_process->pnacl_component_installer()->RegisterPnaclComponent( | 395 g_browser_process->pnacl_component_installer()->RegisterPnaclComponent(cus); |
| 396 cus, command_line); | |
| 397 RegisterWidevineCdmComponent(cus); | 396 RegisterWidevineCdmComponent(cus); |
| 398 #endif | 397 #endif |
| 399 | 398 |
| 400 #if defined(CLD_DATA_FROM_COMPONENT) | 399 #if defined(CLD_DATA_FROM_COMPONENT) |
| 401 RegisterCldComponent(cus); | 400 RegisterCldComponent(cus); |
| 402 #endif | 401 #endif |
| 403 | 402 |
| 404 #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) | 403 #if !defined(OS_CHROMEOS) && !defined(OS_ANDROID) |
| 405 // CRLSetFetcher attempts to load a CRL set from either the local disk or | 404 // CRLSetFetcher attempts to load a CRL set from either the local disk or |
| 406 // network. | 405 // network. |
| (...skipping 1040 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1447 | 1446 |
| 1448 PreBrowserStart(); | 1447 PreBrowserStart(); |
| 1449 | 1448 |
| 1450 // Instantiate the notification UI manager, as this triggers a perf timer | 1449 // Instantiate the notification UI manager, as this triggers a perf timer |
| 1451 // used to measure startup time. TODO(stevenjb): Figure out what is actually | 1450 // used to measure startup time. TODO(stevenjb): Figure out what is actually |
| 1452 // triggering the timer and call that explicitly in the approprate place. | 1451 // triggering the timer and call that explicitly in the approprate place. |
| 1453 // http://crbug.com/105065. | 1452 // http://crbug.com/105065. |
| 1454 browser_process_->notification_ui_manager(); | 1453 browser_process_->notification_ui_manager(); |
| 1455 | 1454 |
| 1456 if (!parsed_command_line().HasSwitch(switches::kDisableComponentUpdate)) | 1455 if (!parsed_command_line().HasSwitch(switches::kDisableComponentUpdate)) |
| 1457 RegisterComponentsForUpdate(parsed_command_line()); | 1456 RegisterComponentsForUpdate(); |
| 1458 | 1457 |
| 1459 #if defined(OS_ANDROID) | 1458 #if defined(OS_ANDROID) |
| 1460 chrome_variations::VariationsService* variations_service = | 1459 chrome_variations::VariationsService* variations_service = |
| 1461 browser_process_->variations_service(); | 1460 browser_process_->variations_service(); |
| 1462 if (variations_service) { | 1461 if (variations_service) { |
| 1463 variations_service->set_policy_pref_service(profile_->GetPrefs()); | 1462 variations_service->set_policy_pref_service(profile_->GetPrefs()); |
| 1464 variations_service->StartRepeatedVariationsSeedFetch(); | 1463 variations_service->StartRepeatedVariationsSeedFetch(); |
| 1465 } | 1464 } |
| 1466 TranslateDownloadManager::RequestLanguageList(profile_->GetPrefs()); | 1465 TranslateDownloadManager::RequestLanguageList(profile_->GetPrefs()); |
| 1467 | 1466 |
| (...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1659 chromeos::CrosSettings::Shutdown(); | 1658 chromeos::CrosSettings::Shutdown(); |
| 1660 #endif | 1659 #endif |
| 1661 #endif | 1660 #endif |
| 1662 } | 1661 } |
| 1663 | 1662 |
| 1664 // Public members: | 1663 // Public members: |
| 1665 | 1664 |
| 1666 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1665 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
| 1667 chrome_extra_parts_.push_back(parts); | 1666 chrome_extra_parts_.push_back(parts); |
| 1668 } | 1667 } |
| OLD | NEW |