| 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/app/chrome_main_delegate.h" | 5 #include "chrome/app/chrome_main_delegate.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/base_paths.h" | 9 #include "base/base_paths.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 623 if (recovery_exit_code) { | 623 if (recovery_exit_code) { |
| 624 // Recovery has failed somehow, so we exit. | 624 // Recovery has failed somehow, so we exit. |
| 625 *exit_code = recovery_exit_code; | 625 *exit_code = recovery_exit_code; |
| 626 return true; | 626 return true; |
| 627 } | 627 } |
| 628 } else { // Not running diagnostics or recovery. | 628 } else { // Not running diagnostics or recovery. |
| 629 diagnostics::DiagnosticsController::GetInstance()->RecordRegularStartup(); | 629 diagnostics::DiagnosticsController::GetInstance()->RecordRegularStartup(); |
| 630 } | 630 } |
| 631 #endif | 631 #endif |
| 632 | 632 |
| 633 if (command_line.HasSwitch(switches::kOriginTrialPublicKey)) { |
| 634 chrome_content_client_.origin_trial_key_manager() |
| 635 ->SetPublicKeyFromASCIIString( |
| 636 command_line.GetSwitchValueASCII(switches::kOriginTrialPublicKey)); |
| 637 } |
| 638 |
| 633 content::SetContentClient(&chrome_content_client_); | 639 content::SetContentClient(&chrome_content_client_); |
| 634 | 640 |
| 635 return false; | 641 return false; |
| 636 } | 642 } |
| 637 | 643 |
| 638 #if defined(OS_MACOSX) | 644 #if defined(OS_MACOSX) |
| 639 void ChromeMainDelegate::InitMacCrashReporter( | 645 void ChromeMainDelegate::InitMacCrashReporter( |
| 640 const base::CommandLine& command_line, | 646 const base::CommandLine& command_line, |
| 641 const std::string& process_type) { | 647 const std::string& process_type) { |
| 642 // TODO(mark): Right now, InitializeCrashpad() needs to be called after | 648 // TODO(mark): Right now, InitializeCrashpad() needs to be called after |
| (...skipping 369 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1012 case version_info::Channel::CANARY: | 1018 case version_info::Channel::CANARY: |
| 1013 return true; | 1019 return true; |
| 1014 case version_info::Channel::DEV: | 1020 case version_info::Channel::DEV: |
| 1015 case version_info::Channel::BETA: | 1021 case version_info::Channel::BETA: |
| 1016 case version_info::Channel::STABLE: | 1022 case version_info::Channel::STABLE: |
| 1017 default: | 1023 default: |
| 1018 // Don't enable instrumentation. | 1024 // Don't enable instrumentation. |
| 1019 return false; | 1025 return false; |
| 1020 } | 1026 } |
| 1021 } | 1027 } |
| OLD | NEW |