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 264 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
275 // issues relating to IPv6, but shouldn't otherwise be needed. Be sure to file | 275 // issues relating to IPv6, but shouldn't otherwise be needed. Be sure to file |
276 // bugs if something isn't working properly in the presence of IPv6. This flag | 276 // bugs if something isn't working properly in the presence of IPv6. This flag |
277 // can be overidden by the "enable-ipv6" flag. | 277 // can be overidden by the "enable-ipv6" flag. |
278 const char kDisableIPv6[] = "disable-ipv6"; | 278 const char kDisableIPv6[] = "disable-ipv6"; |
279 | 279 |
280 // Disable the behavior that the second click on a launcher item (the click when | 280 // Disable the behavior that the second click on a launcher item (the click when |
281 // the item is already active) minimizes the item. | 281 // the item is already active) minimizes the item. |
282 const char kDisableMinimizeOnSecondLauncherItemClick[] = | 282 const char kDisableMinimizeOnSecondLauncherItemClick[] = |
283 "disable-minimize-on-second-launcher-item-click"; | 283 "disable-minimize-on-second-launcher-item-click"; |
284 | 284 |
| 285 // Disable using Mojo for utility process services. |
| 286 const char kDisableMojoUtilityServices[] = "disable-mojo-utility-services"; |
| 287 |
285 // Disables the new bookmark app system. | 288 // Disables the new bookmark app system. |
286 const char kDisableNewBookmarkApps[] = "disable-new-bookmark-apps"; | 289 const char kDisableNewBookmarkApps[] = "disable-new-bookmark-apps"; |
287 | 290 |
288 // Disables the new offline error page generated by NetErrorHelper for ChromeOS | 291 // Disables the new offline error page generated by NetErrorHelper for ChromeOS |
289 // and instead uses the old error page generated by OfflineResourceThrottle. | 292 // and instead uses the old error page generated by OfflineResourceThrottle. |
290 const char kDisableNewOfflineErrorPage[] = "disable-new-offline-error-page"; | 293 const char kDisableNewOfflineErrorPage[] = "disable-new-offline-error-page"; |
291 | 294 |
292 // Disables the menu on the NTP for accessing sessions from other devices. | 295 // Disables the menu on the NTP for accessing sessions from other devices. |
293 const char kDisableNTPOtherSessionsMenu[] = "disable-ntp-other-sessions-menu"; | 296 const char kDisableNTPOtherSessionsMenu[] = "disable-ntp-other-sessions-menu"; |
294 | 297 |
(...skipping 1091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1386 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnablePdfMaterialUI)) | 1389 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnablePdfMaterialUI)) |
1387 return true; | 1390 return true; |
1388 | 1391 |
1389 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kDisablePdfMaterialUI)) | 1392 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kDisablePdfMaterialUI)) |
1390 return false; | 1393 return false; |
1391 | 1394 |
1392 // Default. | 1395 // Default. |
1393 return false; | 1396 return false; |
1394 } | 1397 } |
1395 | 1398 |
| 1399 bool MojoUtilityServicesEnabled() { |
| 1400 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 1401 kDisableMojoUtilityServices)) { |
| 1402 return false; |
| 1403 } |
| 1404 |
| 1405 return true; |
| 1406 } |
| 1407 |
1396 bool SettingsWindowEnabled() { | 1408 bool SettingsWindowEnabled() { |
1397 #if defined(OS_CHROMEOS) | 1409 #if defined(OS_CHROMEOS) |
1398 return !base::CommandLine::ForCurrentProcess()->HasSwitch( | 1410 return !base::CommandLine::ForCurrentProcess()->HasSwitch( |
1399 ::switches::kDisableSettingsWindow); | 1411 ::switches::kDisableSettingsWindow); |
1400 #else | 1412 #else |
1401 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 1413 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
1402 ::switches::kEnableSettingsWindow); | 1414 ::switches::kEnableSettingsWindow); |
1403 #endif | 1415 #endif |
1404 } | 1416 } |
1405 | 1417 |
1406 #if defined(OS_CHROMEOS) | 1418 #if defined(OS_CHROMEOS) |
1407 bool PowerOverlayEnabled() { | 1419 bool PowerOverlayEnabled() { |
1408 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 1420 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
1409 ::switches::kEnablePowerOverlay); | 1421 ::switches::kEnablePowerOverlay); |
1410 } | 1422 } |
1411 #endif | 1423 #endif |
1412 | 1424 |
1413 // ----------------------------------------------------------------------------- | 1425 // ----------------------------------------------------------------------------- |
1414 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE. | 1426 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE. |
1415 // | 1427 // |
1416 // You were going to just dump your switches here, weren't you? Instead, please | 1428 // You were going to just dump your switches here, weren't you? Instead, please |
1417 // put them in alphabetical order above, or in order inside the appropriate | 1429 // put them in alphabetical order above, or in order inside the appropriate |
1418 // ifdef at the bottom. The order should match the header. | 1430 // ifdef at the bottom. The order should match the header. |
1419 // ----------------------------------------------------------------------------- | 1431 // ----------------------------------------------------------------------------- |
1420 | 1432 |
1421 } // namespace switches | 1433 } // namespace switches |
OLD | NEW |