| 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/base_paths.h" | 7 #include "base/base_paths.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/cpu.h" | 9 #include "base/cpu.h" |
| 10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
| (...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 110 #endif | 110 #endif |
| 111 | 111 |
| 112 #if !defined(CHROME_MULTIPLE_DLL_CHILD) | 112 #if !defined(CHROME_MULTIPLE_DLL_CHILD) |
| 113 base::LazyInstance<chrome::ChromeContentBrowserClient> | 113 base::LazyInstance<chrome::ChromeContentBrowserClient> |
| 114 g_chrome_content_browser_client = LAZY_INSTANCE_INITIALIZER; | 114 g_chrome_content_browser_client = LAZY_INSTANCE_INITIALIZER; |
| 115 #endif | 115 #endif |
| 116 | 116 |
| 117 #if !defined(CHROME_MULTIPLE_DLL_BROWSER) | 117 #if !defined(CHROME_MULTIPLE_DLL_BROWSER) |
| 118 base::LazyInstance<ChromeContentRendererClient> | 118 base::LazyInstance<ChromeContentRendererClient> |
| 119 g_chrome_content_renderer_client = LAZY_INSTANCE_INITIALIZER; | 119 g_chrome_content_renderer_client = LAZY_INSTANCE_INITIALIZER; |
| 120 base::LazyInstance<chrome::ChromeContentUtilityClient> | 120 base::LazyInstance<ChromeContentUtilityClient> |
| 121 g_chrome_content_utility_client = LAZY_INSTANCE_INITIALIZER; | 121 g_chrome_content_utility_client = LAZY_INSTANCE_INITIALIZER; |
| 122 base::LazyInstance<chrome::ChromeContentPluginClient> | 122 base::LazyInstance<chrome::ChromeContentPluginClient> |
| 123 g_chrome_content_plugin_client = LAZY_INSTANCE_INITIALIZER; | 123 g_chrome_content_plugin_client = LAZY_INSTANCE_INITIALIZER; |
| 124 #endif | 124 #endif |
| 125 | 125 |
| 126 #if defined(OS_POSIX) | 126 #if defined(OS_POSIX) |
| 127 base::LazyInstance<chrome::ChromeBreakpadClient>::Leaky | 127 base::LazyInstance<chrome::ChromeBreakpadClient>::Leaky |
| 128 g_chrome_breakpad_client = LAZY_INSTANCE_INITIALIZER; | 128 g_chrome_breakpad_client = LAZY_INSTANCE_INITIALIZER; |
| 129 #endif | 129 #endif |
| 130 | 130 |
| (...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 756 PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path); | 756 PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path); |
| 757 ResourceBundle::GetSharedInstance().AddDataPackFromPath( | 757 ResourceBundle::GetSharedInstance().AddDataPackFromPath( |
| 758 resources_pack_path, ui::SCALE_FACTOR_NONE); | 758 resources_pack_path, ui::SCALE_FACTOR_NONE); |
| 759 #endif | 759 #endif |
| 760 CHECK(!loaded_locale.empty()) << "Locale could not be found for " << | 760 CHECK(!loaded_locale.empty()) << "Locale could not be found for " << |
| 761 locale; | 761 locale; |
| 762 | 762 |
| 763 #if !defined(CHROME_MULTIPLE_DLL_BROWSER) | 763 #if !defined(CHROME_MULTIPLE_DLL_BROWSER) |
| 764 if (process_type == switches::kUtilityProcess || | 764 if (process_type == switches::kUtilityProcess || |
| 765 process_type == switches::kZygoteProcess) { | 765 process_type == switches::kZygoteProcess) { |
| 766 chrome::ChromeContentUtilityClient::PreSandboxStartup(); | 766 ChromeContentUtilityClient::PreSandboxStartup(); |
| 767 } | 767 } |
| 768 #endif | 768 #endif |
| 769 } | 769 } |
| 770 | 770 |
| 771 #if defined(OS_POSIX) && !defined(OS_MACOSX) | 771 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
| 772 // Zygote needs to call InitCrashReporter() in RunZygote(). | 772 // Zygote needs to call InitCrashReporter() in RunZygote(). |
| 773 if (process_type != switches::kZygoteProcess) { | 773 if (process_type != switches::kZygoteProcess) { |
| 774 #if defined(OS_ANDROID) | 774 #if defined(OS_ANDROID) |
| 775 if (process_type.empty()) | 775 if (process_type.empty()) |
| 776 breakpad::InitCrashReporter(process_type); | 776 breakpad::InitCrashReporter(process_type); |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 920 } | 920 } |
| 921 | 921 |
| 922 content::ContentUtilityClient* | 922 content::ContentUtilityClient* |
| 923 ChromeMainDelegate::CreateContentUtilityClient() { | 923 ChromeMainDelegate::CreateContentUtilityClient() { |
| 924 #if defined(CHROME_MULTIPLE_DLL_BROWSER) | 924 #if defined(CHROME_MULTIPLE_DLL_BROWSER) |
| 925 return NULL; | 925 return NULL; |
| 926 #else | 926 #else |
| 927 return g_chrome_content_utility_client.Pointer(); | 927 return g_chrome_content_utility_client.Pointer(); |
| 928 #endif | 928 #endif |
| 929 } | 929 } |
| OLD | NEW |