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 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 // issues relating to IPv6, but shouldn't otherwise be needed. Be sure to file | 266 // issues relating to IPv6, but shouldn't otherwise be needed. Be sure to file |
267 // bugs if something isn't working properly in the presence of IPv6. This flag | 267 // bugs if something isn't working properly in the presence of IPv6. This flag |
268 // can be overidden by the "enable-ipv6" flag. | 268 // can be overidden by the "enable-ipv6" flag. |
269 const char kDisableIPv6[] = "disable-ipv6"; | 269 const char kDisableIPv6[] = "disable-ipv6"; |
270 | 270 |
271 // Disable the behavior that the second click on a launcher item (the click when | 271 // Disable the behavior that the second click on a launcher item (the click when |
272 // the item is already active) minimizes the item. | 272 // the item is already active) minimizes the item. |
273 const char kDisableMinimizeOnSecondLauncherItemClick[] = | 273 const char kDisableMinimizeOnSecondLauncherItemClick[] = |
274 "disable-minimize-on-second-launcher-item-click"; | 274 "disable-minimize-on-second-launcher-item-click"; |
275 | 275 |
| 276 // Disable using Mojo for utility process services. |
| 277 const char kDisableMojoUtilityServices[] = "disable-mojo-utility-services"; |
| 278 |
276 // Disables the new bookmark app system. | 279 // Disables the new bookmark app system. |
277 const char kDisableNewBookmarkApps[] = "disable-new-bookmark-apps"; | 280 const char kDisableNewBookmarkApps[] = "disable-new-bookmark-apps"; |
278 | 281 |
279 // Disables the new offline error page generated by NetErrorHelper for ChromeOS | 282 // Disables the new offline error page generated by NetErrorHelper for ChromeOS |
280 // and instead uses the old error page generated by OfflineResourceThrottle. | 283 // and instead uses the old error page generated by OfflineResourceThrottle. |
281 const char kDisableNewOfflineErrorPage[] = "disable-new-offline-error-page"; | 284 const char kDisableNewOfflineErrorPage[] = "disable-new-offline-error-page"; |
282 | 285 |
283 // Disables the menu on the NTP for accessing sessions from other devices. | 286 // Disables the menu on the NTP for accessing sessions from other devices. |
284 const char kDisableNTPOtherSessionsMenu[] = "disable-ntp-other-sessions-menu"; | 287 const char kDisableNTPOtherSessionsMenu[] = "disable-ntp-other-sessions-menu"; |
285 | 288 |
(...skipping 1076 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1362 // Default. | 1365 // Default. |
1363 return false; | 1366 return false; |
1364 } | 1367 } |
1365 | 1368 |
1366 | 1369 |
1367 bool MdSettingsEnabled() { | 1370 bool MdSettingsEnabled() { |
1368 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 1371 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
1369 ::switches::kEnableMaterialDesignSettings); | 1372 ::switches::kEnableMaterialDesignSettings); |
1370 } | 1373 } |
1371 | 1374 |
| 1375 bool MojoUtilityServicesEnabled() { |
| 1376 if (base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 1377 kDisableMojoUtilityServices)) { |
| 1378 return false; |
| 1379 } |
| 1380 |
| 1381 return true; |
| 1382 } |
| 1383 |
1372 bool SettingsWindowEnabled() { | 1384 bool SettingsWindowEnabled() { |
1373 #if defined(OS_CHROMEOS) | 1385 #if defined(OS_CHROMEOS) |
1374 return !base::CommandLine::ForCurrentProcess()->HasSwitch( | 1386 return !base::CommandLine::ForCurrentProcess()->HasSwitch( |
1375 ::switches::kDisableSettingsWindow); | 1387 ::switches::kDisableSettingsWindow); |
1376 #else | 1388 #else |
1377 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 1389 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
1378 ::switches::kEnableSettingsWindow); | 1390 ::switches::kEnableSettingsWindow); |
1379 #endif | 1391 #endif |
1380 } | 1392 } |
1381 | 1393 |
1382 #if defined(OS_CHROMEOS) | 1394 #if defined(OS_CHROMEOS) |
1383 bool PowerOverlayEnabled() { | 1395 bool PowerOverlayEnabled() { |
1384 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 1396 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
1385 ::switches::kEnablePowerOverlay); | 1397 ::switches::kEnablePowerOverlay); |
1386 } | 1398 } |
1387 #endif | 1399 #endif |
1388 | 1400 |
1389 // ----------------------------------------------------------------------------- | 1401 // ----------------------------------------------------------------------------- |
1390 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE. | 1402 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE. |
1391 // | 1403 // |
1392 // You were going to just dump your switches here, weren't you? Instead, please | 1404 // You were going to just dump your switches here, weren't you? Instead, please |
1393 // put them in alphabetical order above, or in order inside the appropriate | 1405 // put them in alphabetical order above, or in order inside the appropriate |
1394 // ifdef at the bottom. The order should match the header. | 1406 // ifdef at the bottom. The order should match the header. |
1395 // ----------------------------------------------------------------------------- | 1407 // ----------------------------------------------------------------------------- |
1396 | 1408 |
1397 } // namespace switches | 1409 } // namespace switches |
OLD | NEW |