| 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 "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/environment.h" | 8 #include "base/environment.h" |
| 9 #include "base/files/file_path.h" | 9 #include "base/files/file_path.h" |
| 10 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
| (...skipping 726 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 737 // sets this up for the browser process in a different manner. Zygotes | 737 // sets this up for the browser process in a different manner. Zygotes |
| 738 // need to call InitCrashReporter() in RunZygote(). | 738 // need to call InitCrashReporter() in RunZygote(). |
| 739 if (!process_type.empty() && process_type != switches::kZygoteProcess) { | 739 if (!process_type.empty() && process_type != switches::kZygoteProcess) { |
| 740 #if defined(OS_ANDROID) | 740 #if defined(OS_ANDROID) |
| 741 InitNonBrowserCrashReporterForAndroid(); | 741 InitNonBrowserCrashReporterForAndroid(); |
| 742 #else | 742 #else |
| 743 InitCrashReporter(); | 743 InitCrashReporter(); |
| 744 #endif | 744 #endif |
| 745 } | 745 } |
| 746 #endif | 746 #endif |
| 747 | |
| 748 #if defined(OS_CHROMEOS) | |
| 749 // Read and cache ChromeOS version from file, | |
| 750 // to be used from inside the sandbox. | |
| 751 int32 major_version, minor_version, bugfix_version; | |
| 752 base::SysInfo::OperatingSystemVersionNumbers( | |
| 753 &major_version, &minor_version, &bugfix_version); | |
| 754 #endif | |
| 755 } | 747 } |
| 756 | 748 |
| 757 void ChromeMainDelegate::SandboxInitialized(const std::string& process_type) { | 749 void ChromeMainDelegate::SandboxInitialized(const std::string& process_type) { |
| 758 startup_timer_->Stop(); // End of Startup Time Measurement. | 750 startup_timer_->Stop(); // End of Startup Time Measurement. |
| 759 | 751 |
| 760 // Note: If you are adding a new process type below, be sure to adjust the | 752 // Note: If you are adding a new process type below, be sure to adjust the |
| 761 // AdjustLinuxOOMScore function too. | 753 // AdjustLinuxOOMScore function too. |
| 762 #if defined(OS_LINUX) | 754 #if defined(OS_LINUX) |
| 763 AdjustLinuxOOMScore(process_type); | 755 AdjustLinuxOOMScore(process_type); |
| 764 #endif | 756 #endif |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 881 } | 873 } |
| 882 | 874 |
| 883 content::ContentUtilityClient* | 875 content::ContentUtilityClient* |
| 884 ChromeMainDelegate::CreateContentUtilityClient() { | 876 ChromeMainDelegate::CreateContentUtilityClient() { |
| 885 #if defined(CHROME_MULTIPLE_DLL_BROWSER) | 877 #if defined(CHROME_MULTIPLE_DLL_BROWSER) |
| 886 return NULL; | 878 return NULL; |
| 887 #else | 879 #else |
| 888 return &g_chrome_content_utility_client.Get(); | 880 return &g_chrome_content_utility_client.Get(); |
| 889 #endif | 881 #endif |
| 890 } | 882 } |
| OLD | NEW |