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
3 // found in the LICENSE file.
5 #include "chrome/common/chrome_switches.h"
7 #include "base/base_switches.h"
8 #include "base/command_line.h"
12 // -----------------------------------------------------------------------------
13 // Can't find the switch you are looking for? Try looking in:
14 // ash/ash_switches.cc
15 // base/base_switches.cc
16 // chromeos/chromeos_switches.cc
19 // When commenting your switch, please use the same voice as surrounding
20 // comments. Imagine "This switch..." at the beginning of the phrase, and it'll
22 // -----------------------------------------------------------------------------
24 // Allows third-party content included on a page to prompt for a HTTP basic
25 // auth username/password pair.
26 const char kAllowCrossOriginAuthPrompt
[] = "allow-cross-origin-auth-prompt";
28 // On ChromeOS, file:// access is disabled except for certain whitelisted
29 // directories. This switch re-enables file:// for testing.
30 const char kAllowFileAccess
[] = "allow-file-access";
32 // Allow non-secure origins to use the screen capture API and the desktopCapture
34 const char kAllowHttpScreenCapture
[] = "allow-http-screen-capture";
36 // Enables TLS/SSL errors on localhost to be ignored (no interstitial,
37 // no blocking of requests).
38 const char kAllowInsecureLocalhost
[] = "allow-insecure-localhost";
40 #if defined(ENABLE_PLUGINS)
41 // Specifies comma-separated list of extension ids or hosts to grant
42 // access to CRX file system APIs.
43 const char kAllowNaClCrxFsAPI
[] = "allow-nacl-crxfs-api";
45 // Specifies comma-separated list of extension ids or hosts to grant
46 // access to file handle APIs.
47 const char kAllowNaClFileHandleAPI
[] = "allow-nacl-file-handle-api";
49 // Specifies comma-separated list of extension ids or hosts to grant
50 // access to TCP/UDP socket APIs.
51 const char kAllowNaClSocketAPI
[] = "allow-nacl-socket-api";
53 // Disables forcing on the experimental Plugin Power Saver feature.
54 const char kDisablePluginPowerSaver
[] = "disable-plugin-power-saver";
56 // Enables forcing on the experimental Plugin Power Saver feature.
57 const char kEnablePluginPowerSaver
[] = "enable-plugin-power-saver";
60 // Don't block outdated plugins.
61 const char kAllowOutdatedPlugins
[] = "allow-outdated-plugins";
63 // By default, an https page cannot run JavaScript, CSS or plugins from http
64 // URLs. This provides an override to get the old insecure behavior.
65 const char kAllowRunningInsecureContent
[] = "allow-running-insecure-content";
67 // Specifies the threshold to be used when determining of an Alternate-Protocol
68 // advertisement will be honored. If the advertised probability is larger
69 // than the threshold, then it will be honored.
70 const char kAlternateProtocolProbabilityThreshold
[] =
71 "alternate-protocol-probability-threshold";
73 // Prevents Chrome from requiring authorization to run certain widely installed
74 // but less commonly used plugins.
75 const char kAlwaysAuthorizePlugins
[] = "always-authorize-plugins";
77 // Specifies that the extension-app with the specified id should be launched
78 // according to its configuration.
79 const char kAppId
[] = "app-id";
81 // Specifies that the associated value should be launched in "application"
83 const char kApp
[] = "app";
85 // Overrides the apps checkout URL, which is used to determine when to expose
87 const char kAppsCheckoutURL
[] = "apps-checkout-url";
89 // The URL that the webstore APIs download extensions from.
90 // Note: the URL must contain one '%s' for the extension ID.
91 const char kAppsGalleryDownloadURL
[] = "apps-gallery-download-url";
93 // The URL to use for the gallery link in the app launcher.
94 const char kAppsGalleryURL
[] = "apps-gallery-url";
96 // The update url used by gallery/webstore extensions.
97 const char kAppsGalleryUpdateURL
[] = "apps-gallery-update-url";
99 // Value of GAIA auth code for --force-app-mode.
100 const char kAppModeAuthCode
[] = "app-mode-auth-code";
102 // Value of OAuth2 refresh token for --force-app-mode.
103 const char kAppModeOAuth2Token
[] = "app-mode-oauth-token";
105 // Enables overriding the path for the default authentication extension.
106 const char kAuthExtensionPath
[] = "auth-ext-path";
108 // A flag that is used to tell Chrome that it was launched automatically at
109 // computer startup and not by some user action.
110 const char kAutoLaunchAtStartup
[] = "auto-launch-at-startup";
112 // This flag makes Chrome auto-select the provided choice when an extension asks
113 // permission to start desktop capture. Should only be used for tests. For
114 // instance, --auto-select-desktop-capture-source="Entire screen" will
115 // automatically select to share the entire screen in English locales.
116 const char kAutoSelectDesktopCaptureSource
[] =
117 "auto-select-desktop-capture-source";
119 // This flag causes the user engagement checks for showing app banners to be
120 // bypasses. It is intended to be used by developers who wish to test that their
121 // sites otherwise meet the criteria needed to show app banners.
122 const char kBypassAppBannerEngagementChecks
[] =
123 "bypass-app-banner-engagement-checks";
125 // Certificate Transparency: Uses the provided log(s) for checking Signed
126 // Certificate Timestamps provided with certificates.
127 // The switch's value is:
128 // log_description:log_key,log_description:log_key,...
130 // log_description is a textual description of the log.
131 // log_key is a Base64'd DER-encoded SubjectPublicKeyInfo of the log's
133 // Multiple logs can be specified by repeating description:key pairs,
134 // separated by a comma.
135 const char kCertificateTransparencyLog
[] =
136 "certificate-transparency-log";
138 // How often (in seconds) to check for updates. Should only be used for testing
140 const char kCheckForUpdateIntervalSec
[] = "check-for-update-interval";
142 // Checks the cloud print connector policy, informing the service process if
143 // the policy is set to disallow the connector, then quits.
144 const char kCheckCloudPrintConnectorPolicy
[] =
145 "check-cloud-print-connector-policy";
147 // Comma-separated list of SSL cipher suites to disable.
148 const char kCipherSuiteBlacklist
[] = "cipher-suite-blacklist";
150 // Tells chrome to display the cloud print dialog and upload the specified file
152 const char kCloudPrintFile
[] = "cloud-print-file";
154 // Specifies the mime type to be used when uploading data from the file
155 // referenced by cloud-print-file. Defaults to "application/pdf" if
157 const char kCloudPrintFileType
[] = "cloud-print-file-type";
159 // Used with kCloudPrintFile to specify a JSON print ticket for the resulting
160 // print job. Defaults to null if unspecified.
161 const char kCloudPrintPrintTicket
[] = "cloud-print-print-ticket";
163 // Used with kCloudPrintFile to specify a title for the resulting print job.
164 const char kCloudPrintJobTitle
[] = "cloud-print-job-title";
166 // Setup cloud print proxy for provided printers. This does not start
167 // service or register proxy for autostart.
168 const char kCloudPrintSetupProxy
[] = "cloud-print-setup-proxy";
170 // Comma-separated list of BrowserThreads that cause browser process to crash
171 // if the given browser thread is not responsive. UI,IO,DB,FILE,CACHE are the
172 // list of BrowserThreads that are supported.
175 // --crash-on-hang-threads=UI:3:18,IO:3:18 --> Crash the browser if UI or IO
176 // is not responsive for 18 seconds and the number of browser threads that
177 // are responding is less than or equal to 3.
178 const char kCrashOnHangThreads
[] = "crash-on-hang-threads";
180 // Some platforms like ChromeOS default to empty desktop.
181 // Browser tests may need to add this switch so that at least one browser
182 // instance is created on startup.
183 // TODO(nkostylev): Investigate if this switch could be removed.
184 // (http://crbug.com/148675)
185 const char kCreateBrowserOnStartupForTests
[] =
186 "create-browser-on-startup-for-tests";
188 // Enables a frame context menu item that toggles the frame in and out of glass
189 // mode (Windows Vista and up only).
190 const char kDebugEnableFrameToggle
[] = "debug-enable-frame-toggle";
192 // Adds debugging entries such as Inspect Element to context menus of packed
194 const char kDebugPackedApps
[] = "debug-packed-apps";
196 // Triggers a plethora of diagnostic modes.
197 const char kDiagnostics
[] = "diagnostics";
199 // Sets the output format for diagnostic modes enabled by diagnostics flag.
200 const char kDiagnosticsFormat
[] = "diagnostics-format";
202 // Tells the diagnostics mode to do the requested recovery step(s).
203 const char kDiagnosticsRecovery
[] = "diagnostics-recovery";
205 // When kEnableSettingsWindow is used, About is shown as an overlay in Settings
206 // instead of as a separate page, unless this flag is specified.
207 const char kDisableAboutInSettings
[] = "disable-about-in-settings";
209 // Disables the experimental asynchronous DNS client.
210 const char kDisableAsyncDns
[] = "disable-async-dns";
212 // Disable several subsystems which run network requests in the background.
213 // This is for use when doing network performance testing to avoid noise in the
215 const char kDisableBackgroundNetworking
[] = "disable-background-networking";
217 // Disables the bundled PPAPI version of Flash.
218 const char kDisableBundledPpapiFlash
[] = "disable-bundled-ppapi-flash";
220 // Disable hardware encoding support for Cast Streaming.
221 const char kDisableCastStreamingHWEncoding
[] =
222 "disable-cast-streaming-hw-encoding";
224 // Disable the requirement of Certificate Transparency presence for EV
225 // certificate. This flag only affects the EV indicator.
226 const char kDisableCertificateTransparencyRequirementForEV
[] =
229 // Disables detection of child accounts.
230 const char kDisableChildAccountDetection
[] =
231 "disable-child-account-detection";
233 // Disables the client-side phishing detection feature. Note that even if
234 // client-side phishing detection is enabled, it will only be active if the
235 // user has opted in to UMA stats and SafeBrowsing is enabled in the
237 const char kDisableClientSidePhishingDetection
[] =
238 "disable-client-side-phishing-detection";
240 // Disable default component extensions with background pages - useful for
241 // performance tests where these pages may interfere with perf results.
242 const char kDisableComponentExtensionsWithBackgroundPages
[] =
243 "disable-component-extensions-with-background-pages";
245 const char kDisableComponentUpdate
[] = "disable-component-update";
247 // Disables installation of default apps on first run. This is used during
248 // automated testing.
249 const char kDisableDefaultApps
[] = "disable-default-apps";
251 // Disables device discovery notifications.
252 const char kDisableDeviceDiscoveryNotifications
[] =
253 "disable-device-discovery-notifications";
255 // Disables the dinosaur easter egg on the offline interstitial.
256 const char kDisableDinosaurEasterEgg
[] = "disable-dinosaur-easter-egg";
258 // Disables Domain Reliability Monitoring.
259 const char kDisableDomainReliability
[] = "disable-domain-reliability";
261 // Disable extensions.
262 const char kDisableExtensions
[] = "disable-extensions";
264 // Disable checking for user opt-in for extensions that want to inject script
265 // into file URLs (ie, always allow it). This is used during automated testing.
266 const char kDisableExtensionsFileAccessCheck
[] =
267 "disable-extensions-file-access-check";
269 // Disable the net::URLRequestThrottlerManager functionality for
270 // requests originating from extensions.
271 const char kDisableExtensionsHttpThrottling
[] =
272 "disable-extensions-http-throttling";
274 // Don't resolve hostnames to IPv6 addresses. This can be used when debugging
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
277 // can be overidden by the "enable-ipv6" flag.
278 const char kDisableIPv6
[] = "disable-ipv6";
280 // Disable the behavior that the second click on a launcher item (the click when
281 // the item is already active) minimizes the item.
282 const char kDisableMinimizeOnSecondLauncherItemClick
[] =
283 "disable-minimize-on-second-launcher-item-click";
285 // Disables the new bookmark app system.
286 const char kDisableNewBookmarkApps
[] = "disable-new-bookmark-apps";
288 // Disables the new offline error page generated by NetErrorHelper for ChromeOS
289 // and instead uses the old error page generated by OfflineResourceThrottle.
290 const char kDisableNewOfflineErrorPage
[] = "disable-new-offline-error-page";
292 // Disables the menu on the NTP for accessing sessions from other devices.
293 const char kDisableNTPOtherSessionsMenu
[] = "disable-ntp-other-sessions-menu";
295 // Disable auto-reload of error pages if offline.
296 const char kDisableOfflineAutoReload
[] = "disable-offline-auto-reload";
298 // Disable only auto-reloading error pages when the tab is visible.
299 const char kDisableOfflineAutoReloadVisibleOnly
[] =
300 "disable-offline-auto-reload-visible-only";
302 // Disable the out of process PDF plugin.
303 const char kDisableOutOfProcessPdf
[] = "disable-out-of-process-pdf";
305 // Disable the setting to prompt the user for their OS account password before
306 // revealing plaintext passwords in the password manager.
307 const char kDisablePasswordManagerReauthentication
[] =
308 "disable-password-manager-reauthentication";
310 // Disable the new material UI - requires out of process PDF plugin.
311 const char kDisablePdfMaterialUI
[] = "disable-pdf-material-ui";
313 // Don't use bubbles for content permissions requests instead of infobars.
314 const char kDisablePermissionsBubbles
[] = "disable-permissions-bubbles";
316 // Disable pop-up blocking.
317 const char kDisablePopupBlocking
[] = "disable-popup-blocking";
319 // Disable speculative TCP/IP preconnection.
320 const char kDisablePreconnect
[] = "disable-preconnect";
322 // Disable prerendering based on local browsing history.
323 const char kDisablePrerenderLocalPredictor
[] =
324 "disable-prerender-local-predictor";
326 // Disables print preview (For testing, and for users who don't like us. :[ )
327 const char kDisablePrintPreview
[] = "disable-print-preview";
329 // Normally when the user attempts to navigate to a page that was the result of
330 // a post we prompt to make sure they want to. This switch may be used to
331 // disable that check. This switch is used during automated testing.
332 const char kDisablePromptOnRepost
[] = "disable-prompt-on-repost";
334 // Disables support for the QUIC protocol.
335 const char kDisableQuic
[] = "disable-quic";
337 // Disable use of pacing of QUIC packets.
338 // This only has an effect if QUIC protocol is enabled.
339 const char kDisableQuicPacing
[] = "disable-quic-pacing";
341 // Disable use of Chromium's port selection for the ephemeral port via bind().
342 // This only has an effect if QUIC protocol is enabled.
343 const char kDisableQuicPortSelection
[] = "disable-quic-port-selection";
345 // Prevents the save password bubble from being enabled.
346 const char kDisableSavePasswordBubble
[] = "disable-save-password-bubble";
348 // Prevents SDCH persistence from being used.
349 const char kDisableSdchPersistence
[] = "disable-sdch-persistence";
351 // Disables using bubbles for session restore request.
352 const char kDisableSessionCrashedBubble
[] = "disable-session-crashed-bubble";
354 // Disables the suggestions service.
355 const char kDisableSuggestionsService
[] = "disable-suggestions-service";
357 // Disables the supervised user host blacklist.
358 const char kDisableSupervisedUserBlacklist
[] =
359 "disable-supervised-user-blacklist";
361 // Disables SafeSites filtering for supervised users.
362 const char kDisableSupervisedUserSafeSites
[] =
363 "disable-supervised-user-safesites";
365 // Disables syncing browser data to a Google Account.
366 const char kDisableSync
[] = "disable-sync";
368 // Disables syncing one or more sync data types that are on by default.
369 // See sync/internal_api/public/base/model_type.h for possible types. Types
370 // should be comma separated, and follow the naming convention for string
371 // representation of model types, e.g.:
372 // --disable-synctypes='Typed URLs, Bookmarks, Autofill Profiles'
373 const char kDisableSyncTypes
[] = "disable-sync-types";
375 // Disables the backend service for web resources.
376 const char kDisableWebResources
[] = "disable-web-resources";
378 // Some tests seem to require the application to close when the last
379 // browser window is closed. Thus, we need a switch to force this behavior
380 // for ChromeOS Aura, disable "zero window mode".
381 // TODO(pkotwicz): Investigate if this bug can be removed.
382 // (http://crbug.com/119175)
383 const char kDisableZeroBrowsersOpenForTests
[] =
384 "disable-zero-browsers-open-for-tests";
386 // Use a specific disk cache location, rather than one derived from the
388 const char kDiskCacheDir
[] = "disk-cache-dir";
390 // Forces the maximum disk space to be used by the disk cache, in bytes.
391 const char kDiskCacheSize
[] = "disk-cache-size";
393 const char kDnsLogDetails
[] = "dns-log-details";
395 // Disables prefetching of DNS information.
396 const char kDnsPrefetchDisable
[] = "dns-prefetch-disable";
398 // Requests that a running browser process dump its collected histograms to a
399 // given file. The file is overwritten if it exists.
400 const char kDumpBrowserHistograms
[] = "dump-browser-histograms";
402 // Overrides the path of Easy Unlock component app.
403 const char kEasyUnlockAppPath
[] = "easy-unlock-app-path";
405 // If set, the app list will be enabled as if enabled from CWS.
406 const char kEnableAppList
[] = "enable-app-list";
408 // Enable OS integration for Chrome app file associations.
409 const char kEnableAppsFileAssociations
[] = "enable-apps-file-associations";
411 // Enables the experimental asynchronous DNS client.
412 const char kEnableAsyncDns
[] = "enable-async-dns";
414 // Enables the benchmarking extensions.
415 const char kEnableBenchmarking
[] = "enable-benchmarking";
417 // Enables the multi-level undo system for bookmarks.
418 const char kEnableBookmarkUndo
[] = "enable-bookmark-undo";
420 // Enables detection of child accounts.
421 const char kEnableChildAccountDetection
[] =
422 "enable-child-account-detection";
424 // This applies only when the process type is "service". Enables the Cloud
425 // Print Proxy component within the service process.
426 const char kEnableCloudPrintProxy
[] = "enable-cloud-print-proxy";
428 // If true devtools experimental settings are enabled.
429 const char kEnableDevToolsExperiments
[] = "enable-devtools-experiments";
431 // Enable device discovery notifications.
432 const char kEnableDeviceDiscoveryNotifications
[] =
433 "enable-device-discovery-notifications";
435 // Enables the DOM distiller.
436 const char kEnableDomDistiller
[] = "enable-dom-distiller";
438 // Enables Domain Reliability Monitoring.
439 const char kEnableDomainReliability
[] = "enable-domain-reliability";
441 // Enables Download Notification.
442 const char kEnableDownloadNotification
[] = "enable-download-notification";
444 // Enable Enhanced Bookmarks.
445 const char kEnhancedBookmarksExperiment
[] = "enhanced-bookmarks-experiment";
447 // Enables experimentation with ephemeral apps to be launched from the webstore.
448 const char kEnableEphemeralAppsInWebstore
[] =
449 "enable-ephemeral-apps-in-webstore";
451 // Enables experimental hotword features specific to always-on.
452 const char kEnableExperimentalHotwordHardware
[] = "enable-hotword-hardware";
454 // Enables logging for extension activity.
455 const char kEnableExtensionActivityLogging
[] =
456 "enable-extension-activity-logging";
458 const char kEnableExtensionActivityLogTesting
[] =
459 "enable-extension-activity-log-testing";
461 // Enable the fast unload controller, which speeds up tab/window close by
462 // running a tab's onunload js handler independently of the GUI -
463 // crbug.com/142458 .
464 const char kEnableFastUnload
[] = "enable-fast-unload";
466 // Enables IPv6 support, even if probes suggest that it may not be fully
467 // supported. Some probes may require internet connections, and this flag will
468 // allow support independent of application testing. This flag overrides
469 // "disable-ipv6" which appears elswhere in this file.
470 const char kEnableIPv6
[] = "enable-ipv6";
472 // Enables experimentation with launching ephemeral apps via hyperlinks.
473 const char kEnableLinkableEphemeralApps
[] = "enable-linkable-ephemeral-apps";
475 // Enables the material design Settings feature.
476 const char kEnableMaterialDesignSettings
[] = "enable-md-settings";
478 // Enables Media Router.
479 const char kEnableMediaRouter
[] = "enable-media-router";
481 // Runs the Native Client inside the renderer process and enables GPU plugin
482 // (internally adds lEnableGpuPlugin to the command line).
483 const char kEnableNaCl
[] = "enable-nacl";
485 // Enables the network-related benchmarking extensions.
486 const char kEnableNetBenchmarking
[] = "enable-net-benchmarking";
488 // Enables the new bookmark app system.
489 const char kEnableNewBookmarkApps
[] = "enable-new-bookmark-apps";
491 // Enables NPN with HTTP. It means NPN is enabled but SPDY won't be used.
492 // HTTP is still used for all requests.
493 const char kEnableNpnHttpOnly
[] = "enable-npn-http";
495 // Enable auto-reload of error pages if offline.
496 const char kEnableOfflineAutoReload
[] = "enable-offline-auto-reload";
498 // Only auto-reload error pages when the tab is visible.
499 const char kEnableOfflineAutoReloadVisibleOnly
[] =
500 "enable-offline-auto-reload-visible-only";
502 // Enable the out of process PDF plugin.
503 const char kEnableOutOfProcessPdf
[] = "enable-out-of-process-pdf";
505 // Enables panels (always on-top docked pop-up windows).
506 const char kEnablePanels
[] = "enable-panels";
508 // Enable the new material UI - requires out of process PDF plugin.
509 const char kEnablePdfMaterialUI
[] = "enable-pdf-material-ui";
511 // Enables presenting plugin placeholder content as shadow DOM.
512 const char kEnablePluginPlaceholderShadowDom
[] =
513 "enable-plugin-placeholder-shadow-dom";
515 // Enables a number of potentially annoying security features (strict mixed
516 // content mode, powerful feature restrictions, etc.)
517 const char kEnablePotentiallyAnnoyingSecurityFeatures
[] =
518 "enable-potentially-annoying-security-features";
520 // Enables the Power overlay in Settings.
521 const char kEnablePowerOverlay
[] = "enable-power-overlay";
523 // Enables showing unregistered printers in print preview
524 const char kEnablePrintPreviewRegisterPromos
[] =
525 "enable-print-preview-register-promos";
527 // Enable Privet storage.
528 const char kEnablePrivetStorage
[] = "enable-privet-storage";
530 // Enables tracking of tasks in profiler for viewing via about:profiler.
531 // To predominantly disable tracking (profiling), use the command line switch:
532 // --enable-profiling=0
533 // Some tracking will still take place at startup, but it will be turned off
534 // during chrome_browser_main.
535 const char kEnableProfiling
[] = "enable-profiling";
537 // Enables query in the omnibox.
538 const char kEnableQueryExtraction
[] = "enable-query-extraction";
540 // Enables support for the QUIC protocol. This is a temporary testing flag.
541 const char kEnableQuic
[] = "enable-quic";
543 // Disable use of pacing of QUIC packets.
544 // This only has an effect if QUIC protocol is enabled.
545 const char kEnableQuicPacing
[] = "enable-quic-pacing";
547 // Enable use of Chromium's port selection for the ephemeral port via bind().
548 // This only has an effect if QUIC protocol is enabled.
549 const char kEnableQuicPortSelection
[] = "enable-quic-port-selection";
551 // Enables context-sensitive reader mode button in the toolbar.
552 const char kEnableReaderModeToolbarIcon
[] =
553 "enable-reader-mode-toolbar-icon";
555 // Enables save password prompt bubble.
556 const char kEnableSavePasswordBubble
[] = "enable-save-password-bubble";
558 // Enables SDCH for https schemes.
559 const char kEnableSdchOverHttps
[] = "enable-sdch-over-https";
561 // Enables SDCH persistence.
562 const char kEnableSdchPersistence
[] = "enable-sdch-persistence";
564 // Enables using bubbles for session restore request instead of infobars.
565 const char kEnableSessionCrashedBubble
[] = "enable-session-crashed-bubble";
567 // Enable or disable settings in a separate browser window per profile
568 // (see SettingsWindowEnabled() below).
569 const char kEnableSettingsWindow
[] = "enable-settings-window";
570 const char kDisableSettingsWindow
[] = "disable-settings-window";
572 // Enable SPDY/4, aka HTTP/2. This is a temporary testing flag.
573 const char kEnableSpdy4
[] = "enable-spdy4";
575 // Enables the suggestions service.
576 const char kEnableSuggestionsService
[] = "enable-suggestions-service";
578 // Enables the supervised user host blacklist.
579 const char kEnableSupervisedUserBlacklist
[] =
580 "enable-supervised-user-blacklist";
582 // Enables the supervised user managed bookmarks folder.
583 const char kEnableSupervisedUserManagedBookmarksFolder
[] =
584 "enable-supervised-user-managed-bookmarks-folder";
586 // Enables SafeSites filtering for supervised users.
587 const char kEnableSupervisedUserSafeSites
[] =
588 "enable-supervised-user-safesites";
590 // Enables synced articles.
591 const char kEnableSyncArticles
[] = "enable-sync-articles";
593 // Enables user control over muting tab audio from the tab strip.
594 const char kEnableTabAudioMuting
[] = "enable-tab-audio-muting";
596 // Enables fanciful thumbnail processing. Used with NTP for
597 // instant-extended-api, where thumbnails are generally smaller.
598 const char kEnableThumbnailRetargeting
[] = "enable-thumbnail-retargeting";
600 // Enables Translate experimental new UX which replaces the infobar.
601 const char kEnableTranslateNewUX
[] = "enable-translate-new-ux";
603 // Enables Alternate-Protocol when the port is user controlled (> 1024).
604 const char kEnableUserAlternateProtocolPorts
[] =
605 "enable-user-controlled-alternate-protocol-ports";
607 // Enables a new "web app" style frame for hosted apps (including bookmark
609 extern const char kEnableWebAppFrame
[] = "enable-web-app-frame";
611 // Enables the Website Settings page on the Settings page.
612 const char kEnableWebsiteSettingsManager
[] = "enable-website-settings-manager";
614 // Enables synchronizing WiFi credentials across devices, using Chrome Sync.
615 const char kEnableWifiCredentialSync
[] = "enable-wifi-credential-sync";
617 // Explicitly allows additional ports using a comma-separated list of port
619 const char kExplicitlyAllowedPorts
[] = "explicitly-allowed-ports";
621 // Values for the kExtensionContentVerification flag.
622 // See ContentVerifierDelegate::Mode for more explanation.
623 const char kExtensionContentVerificationBootstrap
[] = "bootstrap";
624 const char kExtensionContentVerificationEnforceStrict
[] = "enforce_strict";
625 const char kExtensionContentVerificationEnforce
[] = "enforce";
627 // Name of the command line flag to force content verification to be on in one
629 const char kExtensionContentVerification
[] = "extension-content-verification";
631 // Turns on extension install verification if it would not otherwise have been
633 const char kExtensionsInstallVerification
[] = "extensions-install-verification";
635 // Specifies a comma-separated list of extension ids that should be forced to
636 // be treated as not from the webstore when doing install verification.
637 const char kExtensionsNotWebstore
[] = "extensions-not-webstore";
639 // Frequency in seconds for Extensions auto-update.
640 const char kExtensionsUpdateFrequency
[] = "extensions-update-frequency";
642 // Fakes the channel of the browser for purposes of Variations filtering. This
643 // is to be used for testing only. Possible values are "stable", "beta", "dev"
644 // and "canary". Note that this only applies if the browser's reported channel
646 const char kFakeVariationsChannel
[] = "fake-variations-channel";
648 // If this flag is present then this command line is being delegated to an
649 // already running chrome process via the fast path, ie: before chrome.dll is
650 // loaded. It is useful to tell the difference for tracking purposes.
651 const char kFastStart
[] = "fast-start";
653 // These two flags are added around the switches about:flags adds to the
654 // command line. This is useful to see which switches were added by about:flags
655 // on about:version. They don't have any effect.
656 const char kFlagSwitchesBegin
[] = "flag-switches-begin";
657 const char kFlagSwitchesEnd
[] = "flag-switches-end";
659 // Forces application mode. This hides certain system UI elements and forces
660 // the app to be installed if it hasn't been already.
661 const char kForceAppMode
[] = "force-app-mode";
663 // Displays the First Run experience when the browser is started, regardless of
664 // whether or not it's actually the First Run (this overrides kNoFirstRun).
665 const char kForceFirstRun
[] = "force-first-run";
667 // Forces additional Chrome Variation Ids that will be sent in X-Client-Data
668 // header, specified as a 64-bit encoded list of numeric experiment ids. Ids
669 // prefixed with the character "t" will be treated as Trigger Variation Ids.
670 const char kForceVariationIds
[] = "force-variation-ids";
672 // These flags show the man page on Linux. They are equivalent to each
674 const char kHelp
[] = "help";
675 const char kHelpShort
[] = "h";
677 // Makes Windows happy by allowing it to show "Enable access to this program"
678 // checkbox in Add/Remove Programs->Set Program Access and Defaults. This only
679 // shows an error box because the only way to hide Chrome is by uninstalling
681 const char kHideIcons
[] = "hide-icons";
683 // Enables grouping websites by domain and filtering them by period.
684 const char kHistoryEnableGroupByDomain
[] = "enable-grouped-history";
686 // Specifies which page will be displayed in newly-opened tabs. We need this
687 // for testing purposes so that the UI tests don't depend on what comes up for
688 // http://google.com.
689 const char kHomePage
[] = "homepage";
691 // Comma-separated list of rules that control how hostnames are mapped.
694 // "MAP * 127.0.0.1" --> Forces all hostnames to be mapped to 127.0.0.1
695 // "MAP *.google.com proxy" --> Forces all google.com subdomains to be
696 // resolved to "proxy".
697 // "MAP test.com [::1]:77 --> Forces "test.com" to resolve to IPv6 loopback.
698 // Will also force the port of the resulting
699 // socket address to be 77.
700 // "MAP * baz, EXCLUDE www.google.com" --> Remaps everything to "baz",
701 // except for "www.google.com".
703 // These mappings apply to the endpoint host in a net::URLRequest (the TCP
704 // connect and host resolver in a direct connection, and the CONNECT in an http
705 // proxy connection, and the endpoint host in a SOCKS proxy connection).
706 const char kHostRules
[] = "host-rules";
708 // The maximum number of retry attempts to resolve the host. Set this to zero
709 // to disable host resolver retry attempts.
710 const char kHostResolverRetryAttempts
[] = "host-resolver-retry-attempts";
712 // Causes net::URLFetchers to ignore requests for SSL client certificates,
713 // causing them to attempt an unauthenticated SSL/TLS session. This is intended
714 // for use when testing various service URLs (eg: kPromoServerURL, kSbURLPrefix,
715 // kSyncServiceURL, etc)
716 const char kIgnoreUrlFetcherCertRequests
[] =
717 "ignore-urlfetcher-cert-requests";
719 // Causes the browser to launch directly in incognito mode.
720 const char kIncognito
[] = "incognito";
722 // Causes Chrome to initiate an installation flow for the given app.
723 const char kInstallChromeApp
[] = "install-chrome-app";
725 // Causes Chrome to attempt to get metadata from the webstore for the
726 // app/extension ID given, and then prompt the user to download and install it.
727 // This is allowed *only* for ephemeral apps. All other ids will be ignored.
728 const char kInstallEphemeralAppFromWebstore
[] =
729 "install-ephemeral-app-from-webstore";
731 // A list of whitelists to install for a supervised user, for testing.
732 // The list is of the following form: <id>[:<name>],[<id>[:<name>],...]
733 const char kInstallSupervisedUserWhitelists
[] =
734 "install-supervised-user-whitelists";
736 // Marks a renderer as an Instant process.
737 const char kInstantProcess
[] = "instant-process";
739 // Invalidation service should use GCM network channel even if experiment is not
741 const char kInvalidationUseGCMChannel
[] = "invalidation-use-gcm-channel";
743 // Disable latest shipping ECMAScript 6 features.
744 const char kDisableJavaScriptHarmonyShipping
[] =
745 "disable-javascript-harmony-shipping";
747 // Enables experimental Harmony (ECMAScript 6) features.
748 const char kJavaScriptHarmony
[] = "javascript-harmony";
750 // Dumps IPC messages sent from renderer processes to the browser process to
751 // the given directory. Used primarily to gather samples for IPC fuzzing.
752 const char kIpcDumpDirectory
[] = "ipc-dump-directory";
754 // Specifies the testcase used by the IPC fuzzer.
755 const char kIpcFuzzerTestcase
[] = "ipc-fuzzer-testcase";
757 // Used for testing - keeps browser alive after last browser window closes.
758 const char kKeepAliveForTest
[] = "keep-alive-for-test";
760 // Enable Kiosk mode.
761 const char kKioskMode
[] = "kiosk";
763 // Print automatically in kiosk mode. |kKioskMode| must be set as well.
764 // See http://crbug.com/31395.
765 const char kKioskModePrinting
[] = "kiosk-printing";
767 // Comma-separated list of directories with component extensions to load.
768 const char kLoadComponentExtension
[] = "load-component-extension";
770 // Loads an extension from the specified directory.
771 const char kLoadExtension
[] = "load-extension";
773 // Makes Chrome default browser
774 const char kMakeDefaultBrowser
[] = "make-default-browser";
776 // Use to opt-in to marking HTTP as non-secure.
777 const char kMarkNonSecureAs
[] = "mark-non-secure-as";
778 const char kMarkNonSecureAsNeutral
[] = "neutral";
779 const char kMarkNonSecureAsDubious
[] = "dubious";
780 const char kMarkNonSecureAsNonSecure
[] = "non-secure";
782 // Forces the maximum disk space to be used by the media cache, in bytes.
783 const char kMediaCacheSize
[] = "media-cache-size";
785 // Enables histograming of tasks served by MessageLoop. See
786 // about:histograms/Loop for results, which show frequency of messages on each
787 // thread, including APC count, object signalling count, etc.
788 const char kMessageLoopHistogrammer
[] = "message-loop-histogrammer";
790 // Enables the recording of metrics reports but disables reporting. In contrast
791 // to kDisableMetrics, this executes all the code that a normal client would
792 // use for reporting, except the report is dropped rather than sent to the
793 // server. This is useful for finding issues in the metrics code during UI and
794 // performance tests.
795 const char kMetricsRecordingOnly
[] = "metrics-recording-only";
797 // Allows setting a different destination ID for connection-monitoring GCM
798 // messages. Useful when running against a non-prod management server.
799 const char kMonitoringDestinationID
[] = "monitoring-destination-id";
801 // Sets the base logging level for the net log. Log 0 logs the most data.
802 // Intended primarily for use with --log-net-log.
803 const char kNetLogLevel
[] = "net-log-level";
805 // Disables the default browser check. Useful for UI/browser tests where we
806 // want to avoid having the default browser info-bar displayed.
807 const char kNoDefaultBrowserCheck
[] = "no-default-browser-check";
809 // By default, an https page can load images, fonts or frames from an http
810 // page. This switch overrides this to block this lesser mixed-content problem.
811 const char kNoDisplayingInsecureContent
[] = "no-displaying-insecure-content";
813 // Don't record/playback events when using record & playback.
814 const char kNoEvents
[] = "no-events";
816 // Disables all experiments set on about:flags. Does not disable about:flags
817 // itself. Useful if an experiment makes chrome crash at startup: One can start
818 // chrome with --no-experiments, disable the problematic lab at about:flags and
819 // then restart chrome without this switch again.
820 const char kNoExperiments
[] = "no-experiments";
822 // Skip First Run tasks, whether or not it's actually the First Run. Overridden
823 // by kForceFirstRun. This does not drop the First Run sentinel and thus doesn't
824 // prevent first run from occuring the next time chrome is launched without this
826 const char kNoFirstRun
[] = "no-first-run";
828 // Whether or not the browser should warn if the profile is on a network share.
829 // This flag is only relevant for Windows currently.
830 const char kNoNetworkProfileWarning
[] = "no-network-profile-warning";
832 // Don't send hyperlink auditing pings
833 const char kNoPings
[] = "no-pings";
835 // Don't use a proxy server, always make direct connections. Overrides any
836 // other proxy server flags that are passed.
837 const char kNoProxyServer
[] = "no-proxy-server";
839 // Disables the service process from adding itself as an autorun process. This
840 // does not delete existing autorun registrations, it just prevents the service
841 // from registering a new one.
842 const char kNoServiceAutorun
[] = "no-service-autorun";
844 // Does not automatically open a browser window on startup (used when
845 // launching Chrome for the purpose of hosting background apps).
846 const char kNoStartupWindow
[] = "no-startup-window";
848 // Disables checking whether we received an acknowledgment when registering
849 // a supervised user. Also disables the timeout during registration that waits
850 // for the ack. Useful when debugging against a server that does not
851 // support notifications.
852 const char kNoSupervisedUserAcknowledgmentCheck
[] =
853 "no-managed-user-acknowledgment-check";
855 // Specifies the maximum number of threads to use for running the Proxy
856 // Autoconfig (PAC) script.
857 const char kNumPacThreads
[] = "num-pac-threads";
859 // Launches URL in new browser window.
860 const char kOpenInNewWindow
[] = "new-window";
862 // Force use of QUIC for requests to the specified origin.
863 const char kOriginToForceQuicOn
[] = "origin-to-force-quic-on";
865 // The time that a new chrome process which is delegating to an already running
866 // chrome process started. (See ProcessSingleton for more details.)
867 const char kOriginalProcessStartTime
[] = "original-process-start-time";
869 // Packages an extension to a .crx installable file from a given directory.
870 const char kPackExtension
[] = "pack-extension";
872 // Optional PEM private key to use in signing packaged .crx.
873 const char kPackExtensionKey
[] = "pack-extension-key";
875 // Specifies the path to the user data folder for the parent profile.
876 const char kParentProfile
[] = "parent-profile";
878 // Development flag for permission request API. This flag is needed until
879 // the API is finalized.
880 // TODO(bauerb): Remove when this flag is not needed anymore.
881 const char kPermissionRequestApiScope
[] = "permission-request-api-scope";
883 // Development flag for permission request API. This flag is needed until
884 // the API is finalized.
885 // TODO(bauerb): Remove when this flag is not needed anymore.
886 const char kPermissionRequestApiUrl
[] = "permission-request-api-url";
888 // Use the PPAPI (Pepper) Flash found at the given path.
889 const char kPpapiFlashPath
[] = "ppapi-flash-path";
891 // Report the given version for the PPAPI (Pepper) Flash. The version should be
892 // numbers separated by '.'s (e.g., "12.3.456.78"). If not specified, it
893 // defaults to "10.2.999.999".
894 const char kPpapiFlashVersion
[] = "ppapi-flash-version";
896 // Triggers prerendering of search base page to prefetch results for the typed
897 // omnibox query. Only has an effect when prerender is enabled.
898 const char kPrefetchSearchResults
[] = "prefetch-search-results";
900 // Triggers prerendering of pages from suggestions in the omnibox. Only has an
901 // effect when Instant is either disabled or restricted to search, and when
902 // prerender is enabled.
903 const char kPrerenderFromOmnibox
[] = "prerender-from-omnibox";
904 // These are the values the kPrerenderFromOmnibox switch may have, as in
905 // "--prerender-from-omnibox=auto". auto: Allow field trial selection.
906 const char kPrerenderFromOmniboxSwitchValueAuto
[] = "auto";
907 // disabled: No prerendering.
908 const char kPrerenderFromOmniboxSwitchValueDisabled
[] = "disabled";
909 // enabled: Guaranteed prerendering.
910 const char kPrerenderFromOmniboxSwitchValueEnabled
[] = "enabled";
911 // Controls speculative prerendering of pages, and content prefetching. Both
912 // are dispatched from <link rel=prefetch href=...> elements.
913 const char kPrerenderMode
[] = "prerender";
914 // These are the values the kPrerenderMode switch may have, as in
915 // "--prerender=disabled".
916 // disabled: No prerendering.
917 const char kPrerenderModeSwitchValueDisabled
[] = "disabled";
918 // enabled: Prerendering.
919 const char kPrerenderModeSwitchValueEnabled
[] = "enabled";
921 // Use IPv6 only for privet HTTP.
922 const char kPrivetIPv6Only
[] = "privet-ipv6-only";
924 // Outputs the product version information and quit. Used as an internal api to
925 // detect the installed version of Chrome on Linux.
926 const char kProductVersion
[] = "product-version";
928 // Selects directory of profile to associate with the first browser launched.
929 const char kProfileDirectory
[] = "profile-directory";
931 // Starts the sampling based profiler for the browser process at startup. This
932 // will only work if chrome has been built with the gyp variable profiling=1.
933 // The output will go to the value of kProfilingFile.
934 const char kProfilingAtStart
[] = "profiling-at-start";
936 // Specifies a location for profiling output. This will only work if chrome has
937 // been built with the gyp variable profiling=1.
939 // {pid} if present will be replaced by the pid of the process.
940 // {count} if present will be incremented each time a profile is generated
942 // The default is chrome-profile-{pid}.
943 const char kProfilingFile
[] = "profiling-file";
945 // Controls whether profile data is periodically flushed to a file. Normally
946 // the data gets written on exit but cases exist where chrome doesn't exit
947 // cleanly (especially when using single-process). A time in seconds can be
949 const char kProfilingFlush
[] = "profiling-flush";
951 // Forces proxy auto-detection.
952 const char kProxyAutoDetect
[] = "proxy-auto-detect";
954 // Specifies a list of hosts for whom we bypass proxy settings and use direct
955 // connections. Ignored if --proxy-auto-detect or --no-proxy-server are also
956 // specified. This is a comma-separated list of bypass rules. See:
957 // "net/proxy/proxy_bypass_rules.h" for the format of these rules.
958 const char kProxyBypassList
[] = "proxy-bypass-list";
960 // Uses the pac script at the given URL
961 const char kProxyPacUrl
[] = "proxy-pac-url";
963 // Uses a specified proxy server, overrides system settings. This switch only
964 // affects HTTP and HTTPS requests.
965 const char kProxyServer
[] = "proxy-server";
967 // Specifies a comma separated list of QUIC connection options to send to
969 const char kQuicConnectionOptions
[] = "quic-connection-options";
971 // Specifies the maximum length for a QUIC packet.
972 const char kQuicMaxPacketLength
[] = "quic-max-packet-length";
974 // Specifies the version of QUIC to use.
975 const char kQuicVersion
[] = "quic-version";
977 // Remember user proceeds through SSL interstitials for a specified amount of
978 // time. In particular, remember these decisions through session restart. The
979 // time delta to remember certificates should be specified in seconds.
980 const char kRememberCertErrorDecisions
[] = "remember-cert-error-decisions";
982 // If set, the app list will forget it has been installed on startup. Note this
983 // doesn't prevent the app list from running, it just makes Chrome think the app
984 // list hasn't been enabled (as in kEnableAppList) yet.
985 const char kResetAppListInstallState
[] = "reset-app-list-install-state";
987 // Indicates the last session should be restored on startup. This overrides the
988 // preferences value and is primarily intended for testing. The value of this
989 // switch is the number of tabs to wait until loaded before 'load completed' is
990 // sent to the ui_test.
991 const char kRestoreLastSession
[] = "restore-last-session";
993 // Disable saving pages as HTML-only, disable saving pages as HTML Complete
994 // (with a directory of sub-resources). Enable only saving pages as MHTML.
995 // See http://crbug.com/120416 for how to remove this switch.
996 const char kSavePageAsMHTML
[] = "save-page-as-mhtml";
998 // If present, safebrowsing only performs update when
999 // SafeBrowsingProtocolManager::ForceScheduleNextUpdate() is explicitly called.
1000 // This is used for testing only.
1001 const char kSbDisableAutoUpdate
[] = "safebrowsing-disable-auto-update";
1003 // TODO(lzheng): Remove this flag once the feature works fine
1004 // (http://crbug.com/74848).
1006 // Disables safebrowsing feature that checks download url and downloads
1007 // content's hash to make sure the content are not malicious.
1008 const char kSbDisableDownloadProtection
[] =
1009 "safebrowsing-disable-download-protection";
1011 // Disables safebrowsing feature that checks for blacklisted extensions.
1012 const char kSbDisableExtensionBlacklist
[] =
1013 "safebrowsing-disable-extension-blacklist";
1015 // Disables safebrowsing feature that provides a side-effect free whitelist.
1016 const char kSbDisableSideEffectFreeWhitelist
[] =
1017 "safebrowsing-disable-side-effect-free-whitelist";
1019 // Causes the process to run as a service process.
1020 const char kServiceProcess
[] = "service";
1022 // Sets a token in the token service, for testing.
1023 const char kSetToken
[] = "set-token";
1025 // If true the app list will be shown.
1026 const char kShowAppList
[] = "show-app-list";
1029 const char kShowIcons
[] = "show-icons";
1031 // Command line flag offering a "Show saved copy" option to the user if offline.
1032 // The various modes are disabled, primary, or secondary. Primary/secondary
1033 // refers to button placement (for experiment).
1034 const char kShowSavedCopy
[] = "show-saved-copy";
1036 // Values for the kShowSavedCopy flag.
1037 const char kEnableShowSavedCopyPrimary
[] = "primary";
1038 const char kEnableShowSavedCopySecondary
[] = "secondary";
1039 const char kDisableShowSavedCopy
[] = "disable";
1041 // Does not show an infobar when an extension attaches to a page using
1042 // chrome.debugger page. Required to attach to extension background pages.
1043 const char kSilentDebuggerExtensionAPI
[] = "silent-debugger-extension-api";
1045 // Causes Chrome to launch without opening any windows by default. Useful if
1046 // one wishes to use Chrome as an ash server.
1047 const char kSilentLaunch
[] = "silent-launch";
1049 // Simulates that elevation is needed to recover upgrade channel.
1050 const char kSimulateElevatedRecovery
[] = "simulate-elevated-recovery";
1052 // Simulates a critical update being available.
1053 const char kSimulateCriticalUpdate
[] = "simulate-critical-update";
1055 // Simulates that current version is outdated.
1056 const char kSimulateOutdated
[] = "simulate-outdated";
1058 // Simulates that current version is outdated and auto-update is off.
1059 const char kSimulateOutdatedNoAU
[] = "simulate-outdated-no-au";
1061 // Simulates an update being available.
1062 const char kSimulateUpgrade
[] = "simulate-upgrade";
1064 // Speculative resource prefetching.
1065 const char kSpeculativeResourcePrefetching
[] =
1066 "speculative-resource-prefetching";
1068 // Speculative resource prefetching is disabled.
1069 const char kSpeculativeResourcePrefetchingDisabled
[] = "disabled";
1071 // Speculative resource prefetching will only learn about resources that need to
1072 // be prefetched but will not prefetch them.
1073 const char kSpeculativeResourcePrefetchingLearning
[] = "learning";
1075 // Speculative resource prefetching is enabled.
1076 const char kSpeculativeResourcePrefetchingEnabled
[] = "enabled";
1078 #if defined(ENABLE_SPELLCHECK)
1079 // Enables auto correction for misspelled words.
1080 const char kEnableSpellingAutoCorrect
[] = "enable-spelling-auto-correct";
1082 // Enables participation in the field trial for user feedback to spelling
1084 const char kEnableSpellingFeedbackFieldTrial
[] =
1085 "enable-spelling-feedback-field-trial";
1087 // Specifies the URL where spelling service feedback data will be sent instead
1088 // of the default URL. This switch is for temporary testing only.
1089 // TODO(rouslan): Remove this flag when feedback testing is complete. Revisit by
1091 const char kSpellingServiceFeedbackUrl
[] = "spelling-service-feedback-url";
1093 // Specifies the number of seconds between sending batches of feedback to
1094 // spelling service. The default is 30 minutes. The minimum is 5 seconds. This
1095 // switch is for temporary testing only.
1096 // TODO(rouslan): Remove this flag when feedback testing is complete. Revisit by
1098 const char kSpellingServiceFeedbackIntervalSeconds
[] =
1099 "spelling-service-feedback-interval-seconds";
1102 // Specifies the maximum SSL/TLS version ("ssl3", "tls1", "tls1.1", or
1104 const char kSSLVersionMax
[] = "ssl-version-max";
1106 // Specifies the minimum SSL/TLS version ("ssl3", "tls1", "tls1.1", or
1108 const char kSSLVersionMin
[] = "ssl-version-min";
1110 // Specifies the minimum SSL/TLS version ("ssl3", "tls1", "tls1.1", or
1111 // "tls1.2") that TLS fallback will accept.
1112 const char kSSLVersionFallbackMin
[] = "ssl-version-fallback-min";
1114 // These values aren't switches, but rather the values that kSSLVersionMax,
1115 // kSSLVersionMin and kSSLVersionFallbackMin can have.
1116 const char kSSLVersionSSLv3
[] = "ssl3";
1117 const char kSSLVersionTLSv1
[] = "tls1";
1118 const char kSSLVersionTLSv11
[] = "tls1.1";
1119 const char kSSLVersionTLSv12
[] = "tls1.2";
1121 // Starts the browser maximized, regardless of any previous settings.
1122 const char kStartMaximized
[] = "start-maximized";
1124 // Sets the supervised user ID for any loaded or newly created profile to the
1125 // given value. Pass an empty string to mark the profile as non-supervised.
1126 // Used for testing.
1127 const char kSupervisedUserId
[] = "managed-user-id";
1129 // Used to authenticate requests to the Sync service for supervised users.
1130 // Setting this switch also causes Sync to be set up for a supervised user.
1131 const char kSupervisedUserSyncToken
[] = "managed-user-sync-token";
1133 // This flag causes sync to retry very quickly (see polling_constants.h) the
1134 // when it encounters an error, as the first step towards exponential backoff.
1135 const char kSyncShortInitialRetryOverride
[] =
1136 "sync-short-initial-retry-override";
1138 // Overrides the default server used for profile sync.
1139 const char kSyncServiceURL
[] = "sync-url";
1141 // Enables deferring sync backend initialization until user initiated changes
1143 const char kSyncDisableDeferredStartup
[] = "sync-disable-deferred-startup";
1145 // Allows overriding the deferred init fallback timeout.
1146 const char kSyncDeferredStartupTimeoutSeconds
[] =
1147 "sync-deferred-startup-timeout-seconds";
1149 // Enables feature to avoid unnecessary GetUpdate requests.
1150 const char kSyncEnableGetUpdateAvoidance
[] =
1151 "sync-enable-get-update-avoidance";
1153 // Disable data backup when user's not signed in.
1154 const char kSyncDisableBackup
[] = "disable-sync-backup";
1156 // Disable sync rollback.
1157 const char kSyncDisableRollback
[] = "disable-sync-rollback";
1159 // Passes the name of the current running automated test to Chrome.
1160 const char kTestName
[] = "test-name";
1162 // Disables same-origin check on HTTP resources pushed via a SPDY proxy.
1163 // The value is the host:port of the trusted proxy.
1164 const char kTrustedSpdyProxy
[] = "trusted-spdy-proxy";
1166 // Experimental. Shows a dialog asking the user to try chrome. This flag is to
1167 // be used only by the upgrade process.
1168 const char kTryChromeAgain
[] = "try-chrome-again";
1170 // Runs un-installation steps that were done by chrome first-run.
1171 const char kUninstall
[] = "uninstall";
1173 // Overrides per-origin quota settings to unlimited storage for any
1174 // apps/origins. This should be used only for testing purpose.
1175 const char kUnlimitedStorage
[] = "unlimited-storage";
1177 // Uses Spdy for the transport protocol instead of HTTP. This is a temporary
1179 const char kUseSpdy
[] = "use-spdy";
1181 // A string used to override the default user agent with a custom one.
1182 const char kUserAgent
[] = "user-agent";
1184 // Specifies the user data directory, which is where the browser will look for
1185 // all of its state.
1186 const char kUserDataDir
[] = "user-data-dir";
1188 // Examines a .crx for validity and prints the result.
1189 const char kValidateCrx
[] = "validate-crx";
1191 // Uses experimental simple cache backend if possible.
1192 const char kUseSimpleCacheBackend
[] = "use-simple-cache-backend";
1194 // Enables using an in-process Mojo service for the v8 proxy resolver.
1195 const char kV8PacMojoInProcess
[] = "v8-pac-mojo-in-process";
1197 // Enables using an out-of-process Mojo service for the v8 proxy resolver.
1198 const char kV8PacMojoOutOfProcess
[] = "v8-pac-mojo-out-of-process";
1200 // Specifies a custom URL for the server which reports variation data to the
1201 // client. Specifying this switch enables the Variations service on
1202 // unofficial builds. See variations_service.cc.
1203 const char kVariationsServerURL
[] = "variations-server-url";
1205 // Prints version information and quits.
1206 const char kVersion
[] = "version";
1208 // Specify the initial window position: --window-position=x,y
1209 const char kWindowPosition
[] = "window-position";
1211 // Specify the initial window size: --window-size=w,h
1212 const char kWindowSize
[] = "window-size";
1214 // Uses WinHTTP to fetch and evaluate PAC scripts. Otherwise the default is to
1215 // use Chromium's network stack to fetch, and V8 to evaluate.
1216 const char kWinHttpProxyResolver
[] = "winhttp-proxy-resolver";
1218 // Specifies which category option was clicked in the Windows Jumplist that
1219 // resulted in a browser startup.
1220 const char kWinJumplistAction
[] = "win-jumplist-action";
1222 #if defined(OS_ANDROID)
1223 // Disables support for playing videos on Chromecast devices.
1224 const char kDisableCast
[] = "disable-cast";
1226 // Disables Contextual Search.
1227 const char kDisableContextualSearch
[] = "disable-contextual-search";
1229 // Disables zero suggest experiment on Dev channel.
1230 const char kDisableZeroSuggest
[] = "disable-zero-suggest";
1232 // Enable the accessibility tab switcher.
1233 const char kEnableAccessibilityTabSwitcher
[] =
1234 "enable-accessibility-tab-switcher";
1236 // Enables app install alerts.
1237 const char kEnableAppInstallAlerts
[] = "enable-app-install-alerts";
1239 // Enables Contextual Search.
1240 const char kEnableContextualSearch
[] = "enable-contextual-search";
1242 // Enables the DOM distiller animated button UI for Android.
1243 const char kEnableDomDistillerButtonAnimation
[] =
1244 "enable-dom-distiller-button-animation";
1246 // Enables zero suggest functionality on Dev channel, showing most visited
1247 // sites as default suggestions.
1248 const char kEnableZeroSuggestMostVisited
[] =
1249 "enable-zero-suggest-most-visited";
1251 // Enable zero suggest functionality on Dev channel, showing most visited
1252 // sites on non-search-result pages as default suggestions.
1253 const char kEnableZeroSuggestMostVisitedWithoutSerp
[] =
1254 "enable-zero-suggest-most-visited-without-serp";
1256 // Enables instant search clicks feature.
1257 const char kEnableInstantSearchClicks
[] = "enable-instant-search-clicks";
1261 #if defined(USE_ASH)
1262 const char kOpenAsh
[] = "open-ash";
1265 #if defined(OS_POSIX) && !defined(OS_MACOSX) && !defined(OS_CHROMEOS)
1266 // Specifies which password store to use (detect, default, gnome, kwallet).
1267 const char kPasswordStore
[] = "password-store";
1270 #if defined(OS_LINUX) && !defined(OS_CHROMEOS)
1271 // Triggers migration of user data directory to another directory
1272 // specified as a parameter. The migration is done under singleton lock,
1273 // and sanity checks are made to avoid corrupting the profile.
1274 // The browser exits after migration is complete.
1275 const char kMigrateDataDirForSxS
[] = "migrate-data-dir-for-sxs";
1276 #endif // defined(OS_LINUX) && !defined(OS_CHROMEOS)
1278 #if defined(OS_MACOSX)
1279 // Prevents Chrome from quitting when Chrome Apps are open.
1280 const char kAppsKeepChromeAliveInTests
[] = "apps-keep-chrome-alive-in-tests";
1282 // Shows a notification when quitting Chrome with hosted apps running. Default
1283 // behavior is to also quit all hosted apps.
1284 const char kHostedAppQuitNotification
[] = "enable-hosted-app-quit-notification";
1286 // Disables app shim creation for hosted apps on Mac.
1287 const char kDisableHostedAppShimCreation
[] = "disable-hosted-app-shim-creation";
1289 // Forcibly disables Lion-style on newer OSes, to allow developers to test the
1290 // older, SnowLeopard-style fullscreen.
1291 const char kDisableSystemFullscreenForTesting
[] =
1292 "disable-system-fullscreen-for-testing";
1294 // A process type (switches::kProcessType) that relaunches the browser. See
1295 // chrome/browser/mac/relauncher.h.
1296 const char kRelauncherProcess
[] = "relauncher";
1298 // This is how the metrics client ID is passed from the browser process to its
1299 // children. With Crashpad, the metrics client ID is distinct from the crash
1301 const char kMetricsClientID
[] = "metrics-client-id";
1305 // Use bubbles for content permissions requests instead of infobars.
1306 const char kEnablePermissionsBubbles
[] = "enable-permissions-bubbles";
1309 // Fallback to XPS. By default connector uses CDD.
1310 const char kEnableCloudPrintXps
[] = "enable-cloud-print-xps";
1312 // Force-enables the profile shortcut manager. This is needed for tests since
1313 // they use a custom-user-data-dir which disables this.
1314 const char kEnableProfileShortcutManager
[] = "enable-profile-shortcut-manager";
1316 // For the DelegateExecute verb handler to launch Chrome in metro mode on
1317 // Windows 8 and higher. Used when relaunching metro Chrome.
1318 const char kForceImmersive
[] = "force-immersive";
1320 // For the DelegateExecute verb handler to launch Chrome in desktop mode on
1321 // Windows 8 and higher. Used when relaunching metro Chrome.
1322 const char kForceDesktop
[] = "force-desktop";
1324 // Relaunches metro Chrome on Windows 8 and higher using a given shortcut.
1325 const char kRelaunchShortcut
[] = "relaunch-shortcut";
1327 // Requests that Chrome launch the Metro viewer process via the given appid
1328 // (which is assumed to be registered as default browser) and synchronously
1330 const char kViewerLaunchViaAppId
[] = "viewer-launch-via-appid";
1332 // Waits for the given handle to be signaled before relaunching metro Chrome on
1333 // Windows 8 and higher.
1334 const char kWaitForMutex
[] = "wait-for-mutex";
1336 // Indicates that chrome was launched to service a search request in Windows 8.
1337 const char kWindows8Search
[] = "windows8-search";
1340 #if defined(ENABLE_PRINT_PREVIEW) && !defined(OFFICIAL_BUILD)
1341 // Enables support to debug printing subsystem.
1342 const char kDebugPrint
[] = "debug-print";
1346 // Enables overriding the path of file manager extension.
1347 const char kFileManagerExtensionPath
[] = "filemgr-ext-path";
1350 bool AboutInSettingsEnabled() {
1351 return SettingsWindowEnabled() &&
1352 !base::CommandLine::ForCurrentProcess()->HasSwitch(
1353 ::switches::kDisableAboutInSettings
);
1356 bool MdSettingsEnabled() {
1357 return base::CommandLine::ForCurrentProcess()->HasSwitch(
1358 ::switches::kEnableMaterialDesignSettings
);
1361 bool MediaRouterEnabled() {
1362 return base::CommandLine::ForCurrentProcess()->HasSwitch(
1363 ::switches::kEnableMediaRouter
);
1366 // Will return true as a default value if the "disable-new-offline-error-page"
1367 // command-line switch is not available.
1368 bool NewOfflineErrorPageEnabled() {
1369 return !base::CommandLine::ForCurrentProcess()->HasSwitch(
1370 ::switches::kDisableNewOfflineErrorPage
);
1373 bool OutOfProcessPdfEnabled() {
1374 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnableOutOfProcessPdf
))
1377 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
1378 kDisableOutOfProcessPdf
))
1385 bool PdfMaterialUIEnabled() {
1386 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kEnablePdfMaterialUI
))
1389 if (base::CommandLine::ForCurrentProcess()->HasSwitch(kDisablePdfMaterialUI
))
1396 bool SettingsWindowEnabled() {
1397 #if defined(OS_CHROMEOS)
1398 return !base::CommandLine::ForCurrentProcess()->HasSwitch(
1399 ::switches::kDisableSettingsWindow
);
1401 return base::CommandLine::ForCurrentProcess()->HasSwitch(
1402 ::switches::kEnableSettingsWindow
);
1406 #if defined(OS_CHROMEOS)
1407 bool PowerOverlayEnabled() {
1408 return base::CommandLine::ForCurrentProcess()->HasSwitch(
1409 ::switches::kEnablePowerOverlay
);
1413 // -----------------------------------------------------------------------------
1414 // DO NOT ADD YOUR CRAP TO THE BOTTOM OF THIS FILE.
1416 // 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
1418 // ifdef at the bottom. The order should match the header.
1419 // -----------------------------------------------------------------------------
1421 } // namespace switches