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 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
312 | 312 |
313 // Disable the net::URLRequestThrottlerManager functionality for | 313 // Disable the net::URLRequestThrottlerManager functionality for |
314 // requests originating from extensions. | 314 // requests originating from extensions. |
315 const char kDisableExtensionsHttpThrottling[] = | 315 const char kDisableExtensionsHttpThrottling[] = |
316 "disable-extensions-http-throttling"; | 316 "disable-extensions-http-throttling"; |
317 | 317 |
318 // Disable mandatory enforcement of web_accessible_resources in extensions. | 318 // Disable mandatory enforcement of web_accessible_resources in extensions. |
319 const char kDisableExtensionsResourceWhitelist[] = | 319 const char kDisableExtensionsResourceWhitelist[] = |
320 "disable-extensions-resource-whitelist"; | 320 "disable-extensions-resource-whitelist"; |
321 | 321 |
322 // Disables the sandbox for the built-in flash player. | |
323 const char kDisableFlashSandbox[] = "disable-flash-sandbox"; | |
324 | |
325 // Disables improved SafeBrowsing download protection. | 322 // Disables improved SafeBrowsing download protection. |
326 const char kDisableImprovedDownloadProtection[] = | 323 const char kDisableImprovedDownloadProtection[] = |
327 "disable-improved-download-protection"; | 324 "disable-improved-download-protection"; |
328 | 325 |
329 // Disable the Infinite Cache. | 326 // Disable the Infinite Cache. |
330 const char kDisableInfiniteCache[] = "disable-infinite-cache"; | 327 const char kDisableInfiniteCache[] = "disable-infinite-cache"; |
331 | 328 |
332 // Disable the internal Flash Player. | 329 // Disable the internal Flash Player. |
333 const char kDisableInternalFlash[] = "disable-internal-flash"; | 330 const char kDisableInternalFlash[] = "disable-internal-flash"; |
334 | 331 |
(...skipping 266 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
601 | 598 |
602 // Enables password generation when we detect that the user is going through | 599 // Enables password generation when we detect that the user is going through |
603 // account creation. | 600 // account creation. |
604 const char kEnablePasswordGeneration[] = "enable-password-generation"; | 601 const char kEnablePasswordGeneration[] = "enable-password-generation"; |
605 | 602 |
606 // Enables content settings based on host *and* plug-in in the user | 603 // Enables content settings based on host *and* plug-in in the user |
607 // preferences. | 604 // preferences. |
608 const char kEnableResourceContentSettings[] = | 605 const char kEnableResourceContentSettings[] = |
609 "enable-resource-content-settings"; | 606 "enable-resource-content-settings"; |
610 | 607 |
611 // Enables experimental features of better session restore (backing up | |
612 // sessionStorage on disk). See also kDisableRestoreSessionState which disables | |
613 // the less exprimental features which are on by default. | |
614 const char kEnableRestoreSessionState[] = "enable-restore-session-state"; | |
615 | |
616 // Enables the installation and usage of Portable Native Client. | 608 // Enables the installation and usage of Portable Native Client. |
617 const char kEnablePnacl[] = "enable-pnacl"; | 609 const char kEnablePnacl[] = "enable-pnacl"; |
618 | 610 |
619 // Enables tracking of tasks in profiler for viewing via about:profiler. | 611 // Enables tracking of tasks in profiler for viewing via about:profiler. |
620 // To predominantly disable tracking (profiling), use the command line switch: | 612 // To predominantly disable tracking (profiling), use the command line switch: |
621 // --enable-profiling=0 | 613 // --enable-profiling=0 |
622 // Some tracking will still take place at startup, but it will be turned off | 614 // Some tracking will still take place at startup, but it will be turned off |
623 // during chrome_browser_main. | 615 // during chrome_browser_main. |
624 const char kEnableProfiling[] = "enable-profiling"; | 616 const char kEnableProfiling[] = "enable-profiling"; |
625 | 617 |
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
998 // situations where a crash is determined to be particularly interesting. | 990 // situations where a crash is determined to be particularly interesting. |
999 const char kPerformCrashAnalysis[] = "perform-crash-analysis"; | 991 const char kPerformCrashAnalysis[] = "perform-crash-analysis"; |
1000 | 992 |
1001 // Read previously recorded data from the cache. Only cached data is read. | 993 // Read previously recorded data from the cache. Only cached data is read. |
1002 // See kRecordMode. | 994 // See kRecordMode. |
1003 const char kPlaybackMode[] = "playback-mode"; | 995 const char kPlaybackMode[] = "playback-mode"; |
1004 | 996 |
1005 // Overrides the path to the location that PNaCl is installed. | 997 // Overrides the path to the location that PNaCl is installed. |
1006 const char kPnaclDir[] = "pnacl-dir"; | 998 const char kPnaclDir[] = "pnacl-dir"; |
1007 | 999 |
1008 // Controls the PPAPI Flash field trial. Valid values are defined below. If an | |
1009 // unknown value is supplied on the command line, the switch is ignored. | |
1010 // TODO(yzshen): Remove this flag when the field trial is over. | |
1011 const char kPpapiFlashFieldTrial[] = "ppapi-flash-field-trial"; | |
1012 // Forces to disable PPAPI Flash when a new PPAPI Flash is downloaded. | |
1013 const char kPpapiFlashFieldTrialDisableByDefault[] = "disable-by-default"; | |
1014 // Forces to enable PPAPI Flash when a new PPAPI Flash is downloaded. | |
1015 const char kPpapiFlashFieldTrialEnableByDefault[] = "enable-by-default"; | |
1016 | |
1017 // Forces the PPAPI version of Flash (if it's being used) to run in the | 1000 // Forces the PPAPI version of Flash (if it's being used) to run in the |
1018 // renderer process rather than in a separate plugin process. | 1001 // renderer process rather than in a separate plugin process. |
1019 const char kPpapiFlashInProcess[] = "ppapi-flash-in-process"; | 1002 const char kPpapiFlashInProcess[] = "ppapi-flash-in-process"; |
1020 | 1003 |
1021 // Use the PPAPI (Pepper) Flash found at the given path. | 1004 // Use the PPAPI (Pepper) Flash found at the given path. |
1022 const char kPpapiFlashPath[] = "ppapi-flash-path"; | 1005 const char kPpapiFlashPath[] = "ppapi-flash-path"; |
1023 | 1006 |
1024 // Report the given version for the PPAPI (Pepper) Flash. The version should be | 1007 // Report the given version for the PPAPI (Pepper) Flash. The version should be |
1025 // numbers separated by '.'s (e.g., "12.3.456.78"). If not specified, it | 1008 // numbers separated by '.'s (e.g., "12.3.456.78"). If not specified, it |
1026 // defaults to "10.2.999.999". | 1009 // defaults to "10.2.999.999". |
(...skipping 27 matching lines...) Expand all Loading... |
1054 // Enable conversion from vector to raster for any page. | 1037 // Enable conversion from vector to raster for any page. |
1055 const char kPrintRaster[] = "print-raster"; | 1038 const char kPrintRaster[] = "print-raster"; |
1056 | 1039 |
1057 // Outputs the product version information and quit. Used as an internal api to | 1040 // Outputs the product version information and quit. Used as an internal api to |
1058 // detect the installed version of Chrome on Linux. | 1041 // detect the installed version of Chrome on Linux. |
1059 const char kProductVersion[] = "product-version"; | 1042 const char kProductVersion[] = "product-version"; |
1060 | 1043 |
1061 // Selects directory of profile to associate with the first browser launched. | 1044 // Selects directory of profile to associate with the first browser launched. |
1062 const char kProfileDirectory[] = "profile-directory"; | 1045 const char kProfileDirectory[] = "profile-directory"; |
1063 | 1046 |
1064 // Enables the Windows profile desktop shortcuts feature. | |
1065 const char kProfileDesktopShortcuts[] = "enable-profile-desktop-shortcuts"; | |
1066 | |
1067 // Starts the sampling based profiler for the browser process at startup. This | 1047 // Starts the sampling based profiler for the browser process at startup. This |
1068 // will only work if chrome has been built with the gyp variable profiling=1. | 1048 // will only work if chrome has been built with the gyp variable profiling=1. |
1069 // The output will go to the value of kProfilingFile. | 1049 // The output will go to the value of kProfilingFile. |
1070 const char kProfilingAtStart[] = "profiling-at-start"; | 1050 const char kProfilingAtStart[] = "profiling-at-start"; |
1071 | 1051 |
1072 // Specifies a location for profiling output. This will only work if chrome has | 1052 // Specifies a location for profiling output. This will only work if chrome has |
1073 // been built with the gyp variable profiling=1. | 1053 // been built with the gyp variable profiling=1. |
1074 // | 1054 // |
1075 // {pid} if present will be replaced by the pid of the process. | 1055 // {pid} if present will be replaced by the pid of the process. |
1076 // {count} if present will be incremented each time a profile is generated | 1056 // {count} if present will be incremented each time a profile is generated |
(...skipping 471 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1548 | 1528 |
1549 // Relaunches metro Chrome on Windows 8 and higher using a given shortcut. | 1529 // Relaunches metro Chrome on Windows 8 and higher using a given shortcut. |
1550 const char kRelaunchShortcut[] = "relaunch-shortcut"; | 1530 const char kRelaunchShortcut[] = "relaunch-shortcut"; |
1551 | 1531 |
1552 // Waits for the given handle to be signaled before relaunching metro Chrome on | 1532 // Waits for the given handle to be signaled before relaunching metro Chrome on |
1553 // Windows 8 and higher. | 1533 // Windows 8 and higher. |
1554 const char kWaitForMutex[] = "wait-for-mutex"; | 1534 const char kWaitForMutex[] = "wait-for-mutex"; |
1555 #endif | 1535 #endif |
1556 | 1536 |
1557 #if defined(USE_AURA) | 1537 #if defined(USE_AURA) |
1558 // Use NativeTabContentsViewAura instead of the default implementation. | |
1559 const char kDisableTCVA[] = "disable-tcva"; | |
1560 | |
1561 // Opens an Ash window on startup. | 1538 // Opens an Ash window on startup. |
1562 extern const char kOpenAsh[] = "open-ash"; | 1539 extern const char kOpenAsh[] = "open-ash"; |
1563 #endif | 1540 #endif |
1564 | 1541 |
1565 #if defined(USE_ASH) | 1542 #if defined(USE_ASH) |
1566 // Enables the wrench menu items to open/close the Ash desktop. | 1543 // Enables the wrench menu items to open/close the Ash desktop. |
1567 const char kEnableAsh[] = "enable-ash"; | 1544 const char kEnableAsh[] = "enable-ash"; |
1568 #endif | 1545 #endif |
1569 | 1546 |
1570 #ifndef NDEBUG | 1547 #ifndef NDEBUG |
(...skipping 29 matching lines...) Expand all Loading... |
1600 | 1577 |
1601 bool IsFramelessConstrainedDialogEnabled() { | 1578 bool IsFramelessConstrainedDialogEnabled() { |
1602 #if defined(OS_MACOSX) | 1579 #if defined(OS_MACOSX) |
1603 return true; | 1580 return true; |
1604 #endif | 1581 #endif |
1605 return CommandLine::ForCurrentProcess()->HasSwitch( | 1582 return CommandLine::ForCurrentProcess()->HasSwitch( |
1606 switches::kEnableFramelessConstrainedDialogs); | 1583 switches::kEnableFramelessConstrainedDialogs); |
1607 } | 1584 } |
1608 | 1585 |
1609 } // namespace chrome | 1586 } // namespace chrome |
OLD | NEW |