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/common/chrome_switches.h" | 5 #include "chrome/common/chrome_switches.h" |
6 | 6 |
7 #include "base/base_switches.h" | 7 #include "base/base_switches.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 | 9 |
10 namespace switches { | 10 namespace switches { |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 | 194 |
195 // Triggers a plethora of diagnostic modes. | 195 // Triggers a plethora of diagnostic modes. |
196 const char kDiagnostics[] = "diagnostics"; | 196 const char kDiagnostics[] = "diagnostics"; |
197 | 197 |
198 // Sets the output format for diagnostic modes enabled by diagnostics flag. | 198 // Sets the output format for diagnostic modes enabled by diagnostics flag. |
199 const char kDiagnosticsFormat[] = "diagnostics-format"; | 199 const char kDiagnosticsFormat[] = "diagnostics-format"; |
200 | 200 |
201 // Tells the diagnostics mode to do the requested recovery step(s). | 201 // Tells the diagnostics mode to do the requested recovery step(s). |
202 const char kDiagnosticsRecovery[] = "diagnostics-recovery"; | 202 const char kDiagnosticsRecovery[] = "diagnostics-recovery"; |
203 | 203 |
| 204 // When kEnableSettingsWindow is used, About is shown as an overlay in Settings |
| 205 // instead of as a separate page, unless this flag is specified. |
| 206 const char kDisableAboutInSettings[] = "disable-about-in-settings"; |
| 207 |
204 // Disables the experimental asynchronous DNS client. | 208 // Disables the experimental asynchronous DNS client. |
205 const char kDisableAsyncDns[] = "disable-async-dns"; | 209 const char kDisableAsyncDns[] = "disable-async-dns"; |
206 | 210 |
207 // Disables CNAME lookup of the host when generating the Kerberos SPN for a | 211 // Disables CNAME lookup of the host when generating the Kerberos SPN for a |
208 // Negotiate challenge. See HttpAuthHandlerNegotiate::CreateSPN for more | 212 // Negotiate challenge. See HttpAuthHandlerNegotiate::CreateSPN for more |
209 // background. | 213 // background. |
210 const char kDisableAuthNegotiateCnameLookup[] = | 214 const char kDisableAuthNegotiateCnameLookup[] = |
211 "disable-auth-negotiate-cname-lookup"; | 215 "disable-auth-negotiate-cname-lookup"; |
212 | 216 |
213 // Disable several subsystems which run network requests in the background. | 217 // Disable several subsystems which run network requests in the background. |
(...skipping 1128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1342 #if defined(ENABLE_FULL_PRINTING) && !defined(OFFICIAL_BUILD) | 1346 #if defined(ENABLE_FULL_PRINTING) && !defined(OFFICIAL_BUILD) |
1343 // Enables support to debug printing subsystem. | 1347 // Enables support to debug printing subsystem. |
1344 const char kDebugPrint[] = "debug-print"; | 1348 const char kDebugPrint[] = "debug-print"; |
1345 #endif | 1349 #endif |
1346 | 1350 |
1347 #ifndef NDEBUG | 1351 #ifndef NDEBUG |
1348 // Enables overriding the path of file manager extension. | 1352 // Enables overriding the path of file manager extension. |
1349 const char kFileManagerExtensionPath[] = "filemgr-ext-path"; | 1353 const char kFileManagerExtensionPath[] = "filemgr-ext-path"; |
1350 #endif | 1354 #endif |
1351 | 1355 |
| 1356 bool AboutInSettingsEnabled() { |
| 1357 return SettingsWindowEnabled() && |
| 1358 !CommandLine::ForCurrentProcess()->HasSwitch( |
| 1359 ::switches::kDisableAboutInSettings); |
| 1360 } |
| 1361 |
1352 bool SettingsWindowEnabled() { | 1362 bool SettingsWindowEnabled() { |
1353 #if defined(OS_CHROMEOS) | 1363 #if defined(OS_CHROMEOS) |
1354 return !CommandLine::ForCurrentProcess()->HasSwitch( | 1364 return !CommandLine::ForCurrentProcess()->HasSwitch( |
1355 ::switches::kDisableSettingsWindow); | 1365 ::switches::kDisableSettingsWindow); |
1356 #else | 1366 #else |
1357 return CommandLine::ForCurrentProcess()->HasSwitch( | 1367 return CommandLine::ForCurrentProcess()->HasSwitch( |
1358 ::switches::kEnableSettingsWindow); | 1368 ::switches::kEnableSettingsWindow); |
1359 #endif | 1369 #endif |
1360 } | 1370 } |
1361 | 1371 |
1362 // ----------------------------------------------------------------------------- | 1372 // ----------------------------------------------------------------------------- |
1363 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE. | 1373 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE. |
1364 // | 1374 // |
1365 // You were going to just dump your switches here, weren't you? Instead, please | 1375 // You were going to just dump your switches here, weren't you? Instead, please |
1366 // put them in alphabetical order above, or in order inside the appropriate | 1376 // put them in alphabetical order above, or in order inside the appropriate |
1367 // ifdef at the bottom. The order should match the header. | 1377 // ifdef at the bottom. The order should match the header. |
1368 // ----------------------------------------------------------------------------- | 1378 // ----------------------------------------------------------------------------- |
1369 | 1379 |
1370 } // namespace switches | 1380 } // namespace switches |
OLD | NEW |