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_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
139 #include "ui/base/resource/resource_bundle.h" | 139 #include "ui/base/resource/resource_bundle.h" |
140 #include "ui/resources/grit/ui_resources.h" | 140 #include "ui/resources/grit/ui_resources.h" |
141 | 141 |
142 #if defined(OS_WIN) | 142 #if defined(OS_WIN) |
143 #include "base/win/windows_version.h" | 143 #include "base/win/windows_version.h" |
144 #include "chrome/browser/chrome_browser_main_win.h" | 144 #include "chrome/browser/chrome_browser_main_win.h" |
145 #include "sandbox/win/src/sandbox_policy.h" | 145 #include "sandbox/win/src/sandbox_policy.h" |
146 #elif defined(OS_MACOSX) | 146 #elif defined(OS_MACOSX) |
147 #include "chrome/browser/chrome_browser_main_mac.h" | 147 #include "chrome/browser/chrome_browser_main_mac.h" |
148 #include "chrome/browser/spellchecker/spellcheck_message_filter_mac.h" | 148 #include "chrome/browser/spellchecker/spellcheck_message_filter_mac.h" |
149 #include "components/crash/app/breakpad_mac.h" | |
150 #elif defined(OS_CHROMEOS) | 149 #elif defined(OS_CHROMEOS) |
151 #include "chrome/browser/chromeos/chrome_browser_main_chromeos.h" | 150 #include "chrome/browser/chromeos/chrome_browser_main_chromeos.h" |
152 #include "chrome/browser/chromeos/drive/fileapi/file_system_backend_delegate.h" | 151 #include "chrome/browser/chromeos/drive/fileapi/file_system_backend_delegate.h" |
153 #include "chrome/browser/chromeos/file_manager/app_id.h" | 152 #include "chrome/browser/chromeos/file_manager/app_id.h" |
154 #include "chrome/browser/chromeos/file_system_provider/fileapi/backend_delegate.
h" | 153 #include "chrome/browser/chromeos/file_system_provider/fileapi/backend_delegate.
h" |
155 #include "chrome/browser/chromeos/fileapi/file_system_backend.h" | 154 #include "chrome/browser/chromeos/fileapi/file_system_backend.h" |
156 #include "chrome/browser/chromeos/fileapi/mtp_file_system_backend_delegate.h" | 155 #include "chrome/browser/chromeos/fileapi/mtp_file_system_backend_delegate.h" |
157 #include "chrome/browser/chromeos/login/startup_utils.h" | 156 #include "chrome/browser/chromeos/login/startup_utils.h" |
158 #include "chrome/browser/chromeos/system/input_device_settings.h" | 157 #include "chrome/browser/chromeos/system/input_device_settings.h" |
159 #include "chromeos/chromeos_switches.h" | 158 #include "chromeos/chromeos_switches.h" |
(...skipping 1134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1294 return false; | 1293 return false; |
1295 } | 1294 } |
1296 return true; | 1295 return true; |
1297 } | 1296 } |
1298 | 1297 |
1299 } // namespace | 1298 } // namespace |
1300 | 1299 |
1301 void ChromeContentBrowserClient::AppendExtraCommandLineSwitches( | 1300 void ChromeContentBrowserClient::AppendExtraCommandLineSwitches( |
1302 base::CommandLine* command_line, | 1301 base::CommandLine* command_line, |
1303 int child_process_id) { | 1302 int child_process_id) { |
1304 #if defined(OS_POSIX) | 1303 #if defined(OS_POSIX) && !defined(OS_MACOSX) |
1305 if (breakpad::IsCrashReporterEnabled()) { | 1304 if (breakpad::IsCrashReporterEnabled()) { |
1306 scoped_ptr<metrics::ClientInfo> client_info = | 1305 scoped_ptr<metrics::ClientInfo> client_info = |
1307 GoogleUpdateSettings::LoadMetricsClientInfo(); | 1306 GoogleUpdateSettings::LoadMetricsClientInfo(); |
1308 command_line->AppendSwitchASCII(switches::kEnableCrashReporter, | 1307 command_line->AppendSwitchASCII(switches::kEnableCrashReporter, |
1309 client_info ? client_info->client_id | 1308 client_info ? client_info->client_id |
1310 : std::string()); | 1309 : std::string()); |
1311 } | 1310 } |
1312 #endif // defined(OS_POSIX) | 1311 #endif // defined(OS_POSIX) && !defined(OS_MACOSX) |
1313 | 1312 |
1314 if (logging::DialogsAreSuppressed()) | 1313 if (logging::DialogsAreSuppressed()) |
1315 command_line->AppendSwitch(switches::kNoErrorDialogs); | 1314 command_line->AppendSwitch(switches::kNoErrorDialogs); |
1316 | 1315 |
1317 std::string process_type = | 1316 std::string process_type = |
1318 command_line->GetSwitchValueASCII(switches::kProcessType); | 1317 command_line->GetSwitchValueASCII(switches::kProcessType); |
1319 const base::CommandLine& browser_command_line = | 1318 const base::CommandLine& browser_command_line = |
1320 *base::CommandLine::ForCurrentProcess(); | 1319 *base::CommandLine::ForCurrentProcess(); |
1321 | 1320 |
1322 static const char* const kCommonSwitchNames[] = { | 1321 static const char* const kCommonSwitchNames[] = { |
(...skipping 1322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2645 switches::kDisableWebRtcEncryption, | 2644 switches::kDisableWebRtcEncryption, |
2646 }; | 2645 }; |
2647 to_command_line->CopySwitchesFrom(from_command_line, | 2646 to_command_line->CopySwitchesFrom(from_command_line, |
2648 kWebRtcDevSwitchNames, | 2647 kWebRtcDevSwitchNames, |
2649 arraysize(kWebRtcDevSwitchNames)); | 2648 arraysize(kWebRtcDevSwitchNames)); |
2650 } | 2649 } |
2651 } | 2650 } |
2652 #endif // defined(ENABLE_WEBRTC) | 2651 #endif // defined(ENABLE_WEBRTC) |
2653 | 2652 |
2654 } // namespace chrome | 2653 } // namespace chrome |
OLD | NEW |