content_switches.cc revision a3f6a49ab37290eeeb8db0f41ec0f1cb74a68be7
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. 4 5#include "content/public/common/content_switches.h" 6 7namespace switches { 8 9// The number of MSAA samples for canvas2D. Requires MSAA support by GPU to 10// have an effect. 0 disables MSAA. 11const char kAcceleratedCanvas2dMSAASampleCount[] = "canvas-msaa-sample-count"; 12 13// By default, file:// URIs cannot read other file:// URIs. This is an 14// override for developers who need the old behavior for testing. 15const char kAllowFileAccessFromFiles[] = "allow-file-access-from-files"; 16 17// Enables the sandboxed processes to run without a job object assigned to them. 18// This flag is required to allow Chrome to run in RemoteApps or Citrix. This 19// flag can reduce the security of the sandboxed processes and allow them to do 20// certain API calls like shut down Windows or access the clipboard. Also we 21// lose the chance to kill some processes until the outer job that owns them 22// finishes. 23const char kAllowNoSandboxJob[] = "allow-no-sandbox-job"; 24 25// Allows debugging of sandboxed processes (see zygote_main_linux.cc). 26const char kAllowSandboxDebugging[] = "allow-sandbox-debugging"; 27 28// Allow compositing on chrome:// pages. 29const char kAllowWebUICompositing[] = "allow-webui-compositing"; 30 31// The same as kAuditHandles except all handles are enumerated. 32const char kAuditAllHandles[] = "enable-handle-auditing-all"; 33 34// Enumerates and prints a child process' most dangerous handles when it 35// is terminated. 36const char kAuditHandles[] = "enable-handle-auditing"; 37 38// Blacklist the GPU for accelerated compositing. 39const char kBlacklistAcceleratedCompositing[] = 40 "blacklist-accelerated-compositing"; 41 42// Blacklist the GPU for WebGL. 43const char kBlacklistWebGL[] = "blacklist-webgl"; 44 45// Block cross-site documents (i.e., HTML/XML/JSON) from being loaded in 46// subresources when a document is not supposed to read them. This will later 47// allow us to block them from the entire renderer process when site isolation 48// is enabled. 49const char kBlockCrossSiteDocuments[] = "block-cross-site-documents"; 50 51// Causes the browser process to throw an assertion on startup. 52const char kBrowserAssertTest[] = "assert-test"; 53 54// Causes the browser process to crash on startup. 55const char kBrowserCrashTest[] = "crash-test"; 56 57// Path to the exe to run for the renderer and plugin subprocesses. 58const char kBrowserSubprocessPath[] = "browser-subprocess-path"; 59 60// Dumps extra logging about plugin loading to the log file. 61const char kDebugPluginLoading[] = "debug-plugin-loading"; 62 63// Sets the tile size used by composited layers. 64const char kDefaultTileWidth[] = "default-tile-width"; 65const char kDefaultTileHeight[] = "default-tile-height"; 66 67// Disable antialiasing on 2d canvas. 68const char kDisable2dCanvasAntialiasing[] = "disable-canvas-aa"; 69 70// Disables client-visible 3D APIs, in particular WebGL and Pepper 3D. 71// This is controlled by policy and is kept separate from the other 72// enable/disable switches to avoid accidentally regressing the policy 73// support for controlling access to these APIs. 74const char kDisable3DAPIs[] = "disable-3d-apis"; 75 76// Disable gpu-accelerated 2d canvas. 77const char kDisableAccelerated2dCanvas[] = "disable-accelerated-2d-canvas"; 78 79// Disables accelerated compositing. 80const char kDisableAcceleratedCompositing[] = "disable-accelerated-compositing"; 81 82// Disables accelerated compositing for backgrounds of root layers with 83// background-attachment: fixed. 84const char kDisableAcceleratedFixedRootBackground[] = 85 "disable-accelerated-fixed-root-background"; 86 87// Disables the hardware acceleration of 3D CSS and animation. 88const char kDisableAcceleratedLayers[] = "disable-accelerated-layers"; 89 90// Disables accelerated compositing for overflow scroll. 91const char kDisableAcceleratedOverflowScroll[] = 92 "disable-accelerated-overflow-scroll"; 93 94// Disables layer squashing. 95const char kDisableLayerSquashing[] = 96 "disable-layer-squashing"; 97 98// Disable accelerated compositing for scrollable frames. 99const char kDisableAcceleratedScrollableFrames[] = 100 "disable-accelerated-scrollable-frames"; 101 102// Disables the hardware acceleration of plugins. 103const char kDisableAcceleratedPlugins[] = "disable-accelerated-plugins"; 104 105// Disables GPU accelerated video display. 106const char kDisableAcceleratedVideo[] = "disable-accelerated-video"; 107 108// Disables hardware acceleration of video decode, where available. 109const char kDisableAcceleratedVideoDecode[] = 110 "disable-accelerated-video-decode"; 111 112// Disables the alternate window station for the renderer. 113const char kDisableAltWinstation[] = "disable-winsta"; 114 115// Disable the ApplicationCache. 116const char kDisableApplicationCache[] = "disable-application-cache"; 117// 118// TODO(scherkus): remove --disable-audio when we have a proper fallback 119// mechanism. 120const char kDisableAudio[] = "disable-audio"; 121 122// Disable limits on the number of backing stores. Can prevent blinking for 123// users with many windows/tabs and lots of memory. 124const char kDisableBackingStoreLimit[] = "disable-backing-store-limit"; 125 126// Disable browser plugin compositing experiment. 127const char kDisableBrowserPluginCompositing[] = 128 "disable-browser-plugin-compositing"; 129 130// Disable accelerated scrolling by the compositor for frames. 131const char kDisableCompositedScrollingForFrames[] = 132 "disable-composited-scrolling-for-frames"; 133 134// See comment for kEnableCompositingForFixedPosition. 135const char kDisableCompositingForFixedPosition[] = 136 "disable-fixed-position-compositing"; 137 138// See comment for kEnableCompositingForTransition. 139const char kDisableCompositingForTransition[] = 140 "disable-transition-compositing"; 141 142// Disables HTML5 DB support. 143const char kDisableDatabases[] = "disable-databases"; 144 145// Disables the deadline scheduler. 146const char kDisableDeadlineScheduling[] = "disable-deadline-scheduling"; 147 148// Disables delegated renderer. 149const char kDisableDelegatedRenderer[] = "disable-delegated-renderer"; 150 151// Disables desktop notifications (default enabled on windows). 152const char kDisableDesktopNotifications[] = "disable-desktop-notifications"; 153 154// Disables experimental navigator content utils implementation. 155const char kDisableNavigatorContentUtils[] = 156 "disable-navigator-content-utils"; 157 158// Disable device motion events. 159const char kDisableDeviceMotion[] = "disable-device-motion"; 160 161// Disable device orientation events. 162const char kDisableDeviceOrientation[] = "disable-device-orientation"; 163 164// Handles URL requests by NPAPI plugins through the renderer. 165const char kDisableDirectNPAPIRequests[] = "disable-direct-npapi-requests"; 166 167// Disable the per-domain blocking for 3D APIs after GPU reset. 168// This switch is intended only for tests. 169extern const char kDisableDomainBlockingFor3DAPIs[] = 170 "disable-domain-blocking-for-3d-apis"; 171 172// Disable experimental WebGL support. 173const char kDisableExperimentalWebGL[] = "disable-webgl"; 174 175// Disable FileSystem API. 176const char kDisableFileSystem[] = "disable-file-system"; 177 178// Disables sending filters (SkImageFilter objects) between processes over IPC 179const char kDisableFiltersOverIPC[] = "disable-filters-over-ipc"; 180 181const char kDisableFixedPositionCreatesStackingContext[] 182 = "disable-fixed-position-creates-stacking-context"; 183 184// Disable 3D inside of flapper. 185const char kDisableFlash3d[] = "disable-flash-3d"; 186 187// Disable Stage3D inside of flapper. 188const char kDisableFlashStage3d[] = "disable-flash-stage3d"; 189 190// This flag disables force compositing mode and prevents it from being enabled 191// via field trials. 192const char kDisableForceCompositingMode[] = "disable-force-compositing-mode"; 193 194// Disable the JavaScript Full Screen API. 195const char kDisableFullScreen[] = "disable-fullscreen"; 196 197// Suppresses support for the Geolocation javascript API. 198const char kDisableGeolocation[] = "disable-geolocation"; 199 200// Disable deferral of scroll-ending gesture events when a scroll is active. 201const char kDisableGestureDebounce[] = "disable-gesture-debounce"; 202 203const char kDisableGestureTapHighlight[] = "disable-gesture-tap-highlight"; 204 205// Disable GL multisampling. 206const char kDisableGLMultisampling[] = "disable-gl-multisampling"; 207 208// Disables GPU hardware acceleration. If software renderer is not in place, 209// then the GPU process won't launch. 210const char kDisableGpu[] = "disable-gpu"; 211 212// Prevent the compositor from using its GPU implementation. 213const char kDisableGpuCompositing[] = "disable-gpu-compositing"; 214 215// Disable the limit on the number of times the GPU process may be restarted 216// This switch is intended only for tests. 217extern const char kDisableGpuProcessCrashLimit[] = 218 "disable-gpu-process-crash-limit"; 219 220// Do not launch the GPU process shortly after browser process launch. Instead 221// launch it when it is first needed. 222const char kDisableGpuProcessPrelaunch[] = "disable-gpu-process-prelaunch"; 223 224// Disable the GPU process sandbox. 225const char kDisableGpuSandbox[] = "disable-gpu-sandbox"; 226 227// Disable the thread that crashes the GPU process if it stops responding to 228// messages. 229const char kDisableGpuWatchdog[] = "disable-gpu-watchdog"; 230 231// Suppresses hang monitor dialogs in renderer processes. This may allow slow 232// unload handlers on a page to prevent the tab from closing, but the Task 233// Manager can be used to terminate the offending process in this case. 234const char kDisableHangMonitor[] = "disable-hang-monitor"; 235 236// Disable the RenderThread's HistogramCustomizer. 237const char kDisableHistogramCustomizer[] = "disable-histogram-customizer"; 238 239// Disables HTML-based desktop notifications. 240const char kDisableHTMLNotifications[] = "disable-html-notifications"; 241 242// Disable the use of an ImageTransportSurface. This means the GPU process 243// will present the rendered page rather than the browser process. 244const char kDisableImageTransportSurface[] = "disable-image-transport-surface"; 245 246// Prevent Java from running. 247const char kDisableJava[] = "disable-java"; 248 249// Don't execute JavaScript (browser JS like the new tab page still runs). 250const char kDisableJavaScript[] = "disable-javascript"; 251 252// Don't kill a child process when it sends a bad IPC message. Apart 253// from testing, it is a bad idea from a security perspective to enable 254// this switch. 255const char kDisableKillAfterBadIPC[] = "disable-kill-after-bad-ipc"; 256 257// Disables prefixed Encrypted Media API (e.g. webkitGenerateKeyRequest()). 258const char kDisablePrefixedEncryptedMedia[] = 259 "disable-prefixed-encrypted-media"; 260 261// Disable LocalStorage. 262const char kDisableLocalStorage[] = "disable-local-storage"; 263 264// Force logging to be disabled. Logging is enabled by default in debug 265// builds. 266const char kDisableLogging[] = "disable-logging"; 267 268// Allows P2P sockets to talk UDP to other servers without using STUN first. 269// For development only, use with caution. 270// TODO(hubbe): Remove this flag. 271const char kDisableP2PSocketSTUNFilter[] = "disable-p2psocket-stun-filter"; 272 273// Disable Pepper3D. 274const char kDisablePepper3d[] = "disable-pepper-3d"; 275 276// Disables compositor-accelerated touch-screen pinch gestures. 277const char kDisablePinch[] = "disable-pinch"; 278 279// Prevent plugins from running. 280const char kDisablePlugins[] = "disable-plugins"; 281 282// Disable discovering third-party plug-ins. Effectively loading only 283// ones shipped with the browser plus third-party ones as specified by 284// --extra-plugin-dir and --load-plugin switches. 285const char kDisablePluginsDiscovery[] = "disable-plugins-discovery"; 286 287// Disables remote web font support. SVG font should always work whether this 288// option is specified or not. 289const char kDisableRemoteFonts[] = "disable-remote-fonts"; 290 291// Turns off the accessibility in the renderer. 292const char kDisableRendererAccessibility[] = "disable-renderer-accessibility"; 293 294// Disable the seccomp filter sandbox (seccomp-bpf) (Linux only). 295const char kDisableSeccompFilterSandbox[] = "disable-seccomp-filter-sandbox"; 296 297// Disable session storage. 298const char kDisableSessionStorage[] = "disable-session-storage"; 299 300// Disable the setuid sandbox (Linux only). 301const char kDisableSetuidSandbox[] = "disable-setuid-sandbox"; 302 303// Enable shared workers. Functionality not yet complete. 304const char kDisableSharedWorkers[] = "disable-shared-workers"; 305 306// Disables site-specific tailoring to compatibility issues in WebKit. 307const char kDisableSiteSpecificQuirks[] = "disable-site-specific-quirks"; 308 309// Disable smooth scrolling for testing. 310const char kDisableSmoothScrolling[] = "disable-smooth-scrolling"; 311 312// Disables the use of a 3D software rasterizer. 313const char kDisableSoftwareRasterizer[] = "disable-software-rasterizer"; 314 315// Disables speech input. 316const char kDisableSpeechInput[] = "disable-speech-input"; 317 318// Disable False Start in SSL and TLS connections. 319const char kDisableSSLFalseStart[] = "disable-ssl-false-start"; 320 321// Disable multithreaded GPU compositing of web content. 322const char kDisableThreadedCompositing[] = "disable-threaded-compositing"; 323 324// Disables the threaded HTML parser in Blink 325const char kDisableThreadedHTMLParser[] = "disable-threaded-html-parser"; 326 327// Disable accelerated overflow scrolling in corner cases (that would not be 328// handled by enable-accelerated-overflow-scroll). 329const char kDisableUniversalAcceleratedOverflowScroll[] = 330 "disable-universal-accelerated-overflow-scroll"; 331 332// Disables unprefixed Media Source API (i.e., the MediaSource object). 333const char kDisableUnprefixedMediaSource[] = "disable-unprefixed-media-source"; 334 335// Disable CSS Transitions / Animations on the Web Animations model. 336const char kDisableWebAnimationsCSS[] = "disable-web-animations-css"; 337 338// Disables prefixed Media Source API (i.e., the WebKitMediaSource object). 339const char kDisableWebKitMediaSource[] = "disable-webkit-media-source"; 340 341// Don't enforce the same-origin policy. (Used by people testing their sites.) 342const char kDisableWebSecurity[] = "disable-web-security"; 343 344// Disables support for XSLT. 345const char kDisableXSLT[] = "disable-xslt"; 346 347// Disables Blink's XSSAuditor. The XSSAuditor mitigates reflective XSS. 348const char kDisableXSSAuditor[] = "disable-xss-auditor"; 349 350// Specifies if the |DOMAutomationController| needs to be bound in the 351// renderer. This binding happens on per-frame basis and hence can potentially 352// be a performance bottleneck. One should only enable it when automating dom 353// based tests. 354const char kDomAutomationController[] = "dom-automation"; 355 356// Enable gpu-accelerated SVG/W3C filters. 357const char kEnableAcceleratedFilters[] = "enable-accelerated-filters"; 358 359// Enables accelerated compositing for backgrounds of root layers with 360// background-attachment: fixed. Requires kForceCompositingMode. 361const char kEnableAcceleratedFixedRootBackground[] = 362 "enable-accelerated-fixed-root-background"; 363 364// Enables accelerated compositing for overflow scroll. Promotes eligible 365// overflow:scroll elements to layers to enable accelerated scrolling for them. 366const char kEnableAcceleratedOverflowScroll[] = 367 "enable-accelerated-overflow-scroll"; 368 369// Enables experimental feature that maps multiple RenderLayers to 370// one composited layer to avoid pathological layer counts. 371const char kEnableLayerSquashing[] = 372 "enable-layer-squashing"; 373 374// Enables accelerated compositing for scrollable frames for accelerated 375// scrolling for them. Requires kForceCompositingMode. 376const char kEnableAcceleratedScrollableFrames[] = 377 "enable-accelerated-scrollable-frames"; 378 379// Turns on extremely verbose logging of accessibility events. 380const char kEnableAccessibilityLogging[] = "enable-accessibility-logging"; 381 382// Use a BeginImplFrame signal from browser to renderer to schedule rendering. 383const char kEnableBeginFrameScheduling[] = "enable-begin-frame-scheduling"; 384 385// Enables browser plugin for all types of pages. 386const char kEnableBrowserPluginForAllViewTypes[] = 387 "enable-browser-plugin-for-all-view-types"; 388 389// Enables Drag and Drop into and out of Browser Plugin. 390// kEnableBrowserPluginGuestViews must also be set at this time. 391const char kEnableBrowserPluginDragDrop[] = "enable-browser-plugin-drag-drop"; 392 393// Enables accelerated scrolling by the compositor for frames. Requires 394// kForceCompositingMode and kEnableAcceleratedScrollableFrames. 395const char kEnableCompositedScrollingForFrames[] = 396 "enable-composited-scrolling-for-frames"; 397 398// Enable the creation of compositing layers for fixed position 399// elements. Three options are needed to support four possible scenarios: 400// 1. Default (disabled) 401// 2. Enabled always (to allow dogfooding) 402// 3. Disabled always (to give safety fallback for users) 403// 4. Enabled only if we detect a highDPI display 404// 405// Option #4 may soon be the default, because the feature is needed soon for 406// high DPI, but cannot be used (yet) for low DPI. Options #2 and #3 will 407// override Option #4. 408const char kEnableCompositingForFixedPosition[] = 409 "enable-fixed-position-compositing"; 410 411// Enable/Disable the creation of compositing layers for RenderLayers with a 412// transition on a property that supports accelerated animation (that is, 413// opacity, -webkit-transform, and -webkit-filter), even when no animation is 414// running. These options allow for three possible scenarios: 415// 1. Default (enabled only if we dectect a highDPI display) 416// 2. Enabled always. 417// 3. Disabled always. 418const char kEnableCompositingForTransition[] = 419 "enable-transition-compositing"; 420 421// Defer image decoding in WebKit until painting. 422const char kEnableDeferredImageDecoding[] = "enable-deferred-image-decoding"; 423 424// Enables the deadline scheduler. 425const char kEnableDeadlineScheduling[] = "enable-deadline-scheduling"; 426 427// Enables delegated renderer. 428const char kEnableDelegatedRenderer[] = "enable-delegated-renderer"; 429 430// Enables restarting interrupted downloads. 431const char kEnableDownloadResumption[] = "enable-download-resumption"; 432 433// Enables support for Encrypted Media Extensions (e.g. MediaKeys). 434const char kEnableEncryptedMedia[] = "enable-encrypted-media"; 435 436// Enable experimental canvas features, e.g. canvas 2D context attributes 437const char kEnableExperimentalCanvasFeatures[] = 438 "enable-experimental-canvas-features"; 439 440// Enables Web Platform features that are in development. 441const char kEnableExperimentalWebPlatformFeatures[] = 442 "enable-experimental-web-platform-features"; 443 444// Enable an experimental WebSocket implementation. 445const char kEnableExperimentalWebSocket[] = "enable-experimental-websocket"; 446 447// Enable the fast text autosizing implementation. 448const char kEnableFastTextAutosizing[] = "enable-fast-text-autosizing"; 449 450const char kEnableFixedPositionCreatesStackingContext[] 451 = "enable-fixed-position-creates-stacking-context"; 452 453// Enable Gesture Tap Highlight 454const char kEnableGestureTapHighlight[] = "enable-gesture-tap-highlight"; 455 456// Enables the GPU benchmarking extension 457const char kEnableGpuBenchmarking[] = "enable-gpu-benchmarking"; 458 459// Enables TRACE for GL calls in the renderer. 460const char kEnableGpuClientTracing[] = "enable-gpu-client-tracing"; 461 462// See comment for kEnableCompositingForFixedPosition. 463const char kEnableHighDpiCompositingForFixedPosition[] = 464 "enable-high-dpi-fixed-position-compositing"; 465 466#if defined(OS_WIN) 467// Enables the DirectWrite font rendering system on windows. 468const char kEnableDirectWrite[] = "enable-direct-write"; 469 470// Use high resolution timers for TimeTicks. 471const char kEnableHighResolutionTime[] = "enable-high-resolution-time"; 472#endif 473 474// Enable HTML Imports 475extern const char kEnableHTMLImports[] = "enable-html-imports"; 476 477// Enables support for inband text tracks in media content. 478const char kEnableInbandTextTracks[] = "enable-inband-text-tracks"; 479 480// Enable inputmode attribute of HTML input or text element. 481extern const char kEnableInputModeAttribute[] = "enable-input-mode-attribute"; 482 483// Force logging to be enabled. Logging is disabled by default in release 484// builds. 485const char kEnableLogging[] = "enable-logging"; 486 487// Enables the memory benchmarking extension 488const char kEnableMemoryBenchmarking[] = "enable-memory-benchmarking"; 489 490// On Windows, converts the page to the currently-installed monitor profile. 491// This does NOT enable color management for images. The source is still 492// assumed to be sRGB. 493const char kEnableMonitorProfile[] = "enable-monitor-profile"; 494 495// Enables use of cache if offline, even if it's stale 496const char kEnableOfflineCacheAccess[] = "enable-offline-cache-access"; 497 498// Enables use of hardware overlay for fullscreen video playback. Android only. 499const char kEnableOverlayFullscreenVideo[] = "enable-overlay-fullscreen-video"; 500 501// Enables overlay scrollbars on Aura or Linux. Does nothing on Mac. 502const char kEnableOverlayScrollbars[] = "enable-overlay-scrollbars"; 503 504// Forward overscroll event data from the renderer to the browser. 505const char kEnableOverscrollNotifications[] = "enable-overscroll-notifications"; 506 507// Enables compositor-accelerated touch-screen pinch gestures. 508const char kEnablePinch[] = "enable-pinch"; 509 510// Enable caching of pre-parsed JS script data. See http://crbug.com/32407. 511const char kEnablePreparsedJsCaching[] = "enable-preparsed-js-caching"; 512 513// Enable privileged WebGL extensions; without this switch such extensions are 514// available only to Chrome extensions. 515const char kEnablePrivilegedWebGLExtensions[] = 516 "enable-privileged-webgl-extensions"; 517 518// Aggressively free GPU command buffers belonging to hidden tabs. 519const char kEnablePruneGpuCommandBuffers[] = 520 "enable-prune-gpu-command-buffers"; 521 522// Enables the CSS multicol implementation that uses the regions implementation. 523const char kEnableRegionBasedColumns[] = 524 "enable-region-based-columns"; 525 526// Enables the new layout/paint system which paints after layout is complete. 527const char kEnableRepaintAfterLayout[] = 528 "enable-repaint-after-layout"; 529 530// Cause the OS X sandbox write to syslog every time an access to a resource 531// is denied by the sandbox. 532const char kEnableSandboxLogging[] = "enable-sandbox-logging"; 533 534// Enables the Skia benchmarking extension 535const char kEnableSkiaBenchmarking[] = "enable-skia-benchmarking"; 536 537// On platforms that support it, enables smooth scroll animation. 538const char kEnableSmoothScrolling[] = "enable-smooth-scrolling"; 539 540// Allow the compositor to use its software implementation if GL fails. 541const char kEnableSoftwareCompositing[] = "enable-software-compositing"; 542 543// Enable spatial navigation 544const char kEnableSpatialNavigation[] = "enable-spatial-navigation"; 545 546// Enables the synthesis part of the Web Speech API. 547const char kEnableSpeechSynthesis[] = "enable-speech-synthesis"; 548 549// Enables TLS cached info extension. 550const char kEnableSSLCachedInfo[] = "enable-ssl-cached-info"; 551 552// Enables StatsTable, logging statistics to a global named shared memory table. 553const char kEnableStatsTable[] = "enable-stats-table"; 554 555// Experimentally ensures that each renderer process: 556// 1) Only handles rendering for pages from a single site, apart from iframes. 557// (Note that a page can reference content from multiple origins due to images, 558// JavaScript files, etc. Cross-site iframes are also loaded in-process.) 559// 2) Only has authority to see or use cookies for the page's top-level origin. 560// (So if a.com iframes b.com, the b.com network request will be sent without 561// cookies.) 562// This is expected to break compatibility with many pages for now. Unlike the 563// --site-per-process flag, this allows cross-site iframes, but it blocks all 564// cookies on cross-site requests. 565const char kEnableStrictSiteIsolation[] = "enable-strict-site-isolation"; 566 567// Enable support for ServiceWorker. See 568// https://github.com/slightlyoff/ServiceWorker for more information. 569const char kEnableServiceWorker[] = "enable-service-worker"; 570 571// Enable use of experimental TCP sockets API for sending data in the 572// SYN packet. 573const char kEnableTcpFastOpen[] = "enable-tcp-fastopen"; 574 575// Enable Text Service Framework(TSF) for text inputting instead of IMM32. This 576// flag is ignored on Metro environment. 577const char kEnableTextServicesFramework[] = "enable-text-services-framework"; 578 579// Enable multithreaded GPU compositing of web content. 580const char kEnableThreadedCompositing[] = "enable-threaded-compositing"; 581 582// Enable accelerated overflow scrolling in all cases. 583const char kEnableUniversalAcceleratedOverflowScroll[] = 584 "enable-universal-accelerated-overflow-scroll"; 585 586// Enable screen capturing support for MediaStream API. 587const char kEnableUserMediaScreenCapturing[] = 588 "enable-usermedia-screen-capturing"; 589 590// Enables the use of the @viewport CSS rule, which allows 591// pages to control aspects of their own layout. This also turns on touch-screen 592// pinch gestures. 593const char kEnableViewport[] = "enable-viewport"; 594 595// Enables the use of the legacy viewport meta tag. Turning this on also 596// turns on the @viewport CSS rule 597const char kEnableViewportMeta[] = "enable-viewport-meta"; 598 599// Resizes of the main frame are the caused by changing between landscape 600// and portrait mode (i.e. Android) so the page should be rescaled to fit 601const char kMainFrameResizesAreOrientationChanges[] = 602 "main-frame-resizes-are-orientation-changes"; 603 604// Enables moving cursor by word in visual order. 605const char kEnableVisualWordMovement[] = "enable-visual-word-movement"; 606 607// Enable the Vtune profiler support. 608const char kEnableVtune[] = "enable-vtune-support"; 609 610// Enable CSS Transitions / Animations on the Web Animations model. 611const char kEnableWebAnimationsCSS[] = "enable-web-animations-css"; 612 613// Enable SVG Animations on the Web Animations model. 614const char kEnableWebAnimationsSVG[] = "enable-web-animations-svg"; 615 616// Enables WebGL extensions not yet approved by the community. 617const char kEnableWebGLDraftExtensions[] = "enable-webgl-draft-extensions"; 618 619// Enables Web MIDI API. 620const char kEnableWebMIDI[] = "enable-web-midi"; 621 622// Load NPAPI plugins from the specified directory. 623const char kExtraPluginDir[] = "extra-plugin-dir"; 624 625// If accelerated compositing is supported, always enter compositing mode for 626// the base layer even when compositing is not strictly required. 627const char kForceCompositingMode[] = "force-compositing-mode"; 628 629// Some field trials may be randomized in the browser, and the randomly selected 630// outcome needs to be propagated to the renderer. For instance, this is used 631// to modify histograms recorded in the renderer, or to get the renderer to 632// also set of its state (initialize, or not initialize components) to match the 633// experiment(s). The option is also useful for forcing field trials when 634// testing changes locally. The argument is a list of name and value pairs, 635// separated by slashes. See FieldTrialList::CreateTrialsFromString() in 636// field_trial.h for details. 637const char kForceFieldTrials[] = "force-fieldtrials"; 638 639// Force renderer accessibility to be on instead of enabling it on demand when 640// a screen reader is detected. The disable-renderer-accessibility switch 641// overrides this if present. 642const char kForceRendererAccessibility[] = "force-renderer-accessibility"; 643 644// Passes gpu device_id from browser process to GPU process. 645const char kGpuDeviceID[] = "gpu-device-id"; 646 647// Passes gpu driver_vendor from browser process to GPU process. 648const char kGpuDriverVendor[] = "gpu-driver-vendor"; 649 650// Passes gpu driver_version from browser process to GPU process. 651const char kGpuDriverVersion[] = "gpu-driver-version"; 652 653// Extra command line options for launching the GPU process (normally used 654// for debugging). Use like renderer-cmd-prefix. 655const char kGpuLauncher[] = "gpu-launcher"; 656 657// Makes this process a GPU sub-process. 658const char kGpuProcess[] = "gpu-process"; 659 660// Allow shmat system call in GPU sandbox. 661const char kGpuSandboxAllowSysVShm[] = "gpu-sandbox-allow-sysv-shm"; 662 663// Causes the GPU process to display a dialog on launch. 664const char kGpuStartupDialog[] = "gpu-startup-dialog"; 665 666// Passes gpu vendor_id from browser process to GPU process. 667const char kGpuVendorID[] = "gpu-vendor-id"; 668 669// These mappings only apply to the host resolver. 670const char kHostResolverRules[] = "host-resolver-rules"; 671 672// Ignores certificate-related errors. 673const char kIgnoreCertificateErrors[] = "ignore-certificate-errors"; 674 675// Ignores GPU blacklist. 676const char kIgnoreGpuBlacklist[] = "ignore-gpu-blacklist"; 677 678// Run the GPU process as a thread in the browser process. 679const char kInProcessGPU[] = "in-process-gpu"; 680 681// Runs plugins inside the renderer process 682const char kInProcessPlugins[] = "in-process-plugins"; 683 684// Specifies the flags passed to JS engine 685const char kJavaScriptFlags[] = "js-flags"; 686 687// Load an NPAPI plugin from the specified path. 688const char kLoadPlugin[] = "load-plugin"; 689 690// Logs GPU control list decisions when enforcing blacklist rules. 691const char kLogGpuControlListDecisions[] = "log-gpu-control-list-decisions"; 692 693// Sets the minimum log level. Valid values are from 0 to 3: 694// INFO = 0, WARNING = 1, LOG_ERROR = 2, LOG_FATAL = 3. 695const char kLoggingLevel[] = "log-level"; 696 697// Enables displaying net log events on the command line, or writing the events 698// to a separate file if a file name is given. 699const char kLogNetLog[] = "log-net-log"; 700 701// Make plugin processes log their sent and received messages to VLOG(1). 702const char kLogPluginMessages[] = "log-plugin-messages"; 703 704// Sets the width and height above which a composited layer will get tiled. 705const char kMaxUntiledLayerHeight[] = "max-untiled-layer-height"; 706const char kMaxUntiledLayerWidth[] = "max-untiled-layer-width"; 707 708// Sample memory usage with high frequency and store the results to the 709// Renderer.Memory histogram. Used in memory tests. 710const char kMemoryMetrics[] = "memory-metrics"; 711 712// Mutes audio sent to the audio device so it is not audible during 713// automated testing. 714const char kMuteAudio[] = "mute-audio"; 715 716// Don't send HTTP-Referer headers. 717const char kNoReferrers[] = "no-referrers"; 718 719// Disables the sandbox for all process types that are normally sandboxed. 720const char kNoSandbox[] = "no-sandbox"; 721 722// Enables or disables history navigation in response to horizontal overscroll. 723// Set the value to '1' to enable the feature, and set to '0' to disable. 724// Defaults to enabled. 725const char kOverscrollHistoryNavigation[] = 726 "overscroll-history-navigation"; 727 728// Specifies a command that should be used to launch the plugin process. Useful 729// for running the plugin process through purify or quantify. Ex: 730// --plugin-launcher="path\to\purify /Run=yes" 731const char kPluginLauncher[] = "plugin-launcher"; 732 733// Tells the plugin process the path of the plugin to load 734const char kPluginPath[] = "plugin-path"; 735 736// Causes the process to run as a plugin subprocess. 737const char kPluginProcess[] = "plugin"; 738 739// Causes the plugin process to display a dialog on launch. 740const char kPluginStartupDialog[] = "plugin-startup-dialog"; 741 742// Argument to the process type that indicates a PPAPI broker process type. 743const char kPpapiBrokerProcess[] = "ppapi-broker"; 744 745// "Command-line" arguments for the PPAPI Flash; used for debugging options. 746const char kPpapiFlashArgs[] = "ppapi-flash-args"; 747 748// Runs PPAPI (Pepper) plugins in-process. 749const char kPpapiInProcess[] = "ppapi-in-process"; 750 751// Like kPluginLauncher for PPAPI plugins. 752const char kPpapiPluginLauncher[] = "ppapi-plugin-launcher"; 753 754// Argument to the process type that indicates a PPAPI plugin process type. 755const char kPpapiPluginProcess[] = "ppapi"; 756 757// Causes the PPAPI sub process to display a dialog on launch. Be sure to use 758// --no-sandbox as well or the sandbox won't allow the dialog to display. 759const char kPpapiStartupDialog[] = "ppapi-startup-dialog"; 760 761// Runs a single process for each site (i.e., group of pages from the same 762// registered domain) the user visits. We default to using a renderer process 763// for each site instance (i.e., group of pages from the same registered 764// domain with script connections to each other). 765const char kProcessPerSite[] = "process-per-site"; 766 767// Runs each set of script-connected tabs (i.e., a BrowsingInstance) in its own 768// renderer process. We default to using a renderer process for each 769// site instance (i.e., group of pages from the same registered domain with 770// script connections to each other). 771const char kProcessPerTab[] = "process-per-tab"; 772 773// The value of this switch determines whether the process is started as a 774// renderer or plugin host. If it's empty, it's the browser. 775const char kProcessType[] = "type"; 776 777// Reduces the GPU process sandbox to be less strict. 778const char kReduceGpuSandbox[] = "reduce-gpu-sandbox"; 779 780// Register Pepper plugins (see pepper_plugin_list.cc for its format). 781const char kRegisterPepperPlugins[] = "register-pepper-plugins"; 782 783 784// Enables remote debug over HTTP on the specified port. 785const char kRemoteDebuggingPort[] = "remote-debugging-port"; 786 787// Causes the renderer process to throw an assertion on launch. 788const char kRendererAssertTest[] = "renderer-assert-test"; 789 790// On POSIX only: the contents of this flag are prepended to the renderer 791// command line. Useful values might be "valgrind" or "xterm -e gdb --args". 792const char kRendererCmdPrefix[] = "renderer-cmd-prefix"; 793 794// Causes the process to run as renderer instead of as browser. 795const char kRendererProcess[] = "renderer"; 796 797// Overrides the default/calculated limit to the number of renderer processes. 798// Very high values for this setting can lead to high memory/resource usage 799// or instability. 800const char kRendererProcessLimit[] = "renderer-process-limit"; 801 802// Causes the renderer process to display a dialog on launch. 803const char kRendererStartupDialog[] = "renderer-startup-dialog"; 804 805// Causes the process to run as a sandbox IPC subprocess. 806const char kSandboxIPCProcess[] = "sandbox-ipc"; 807 808// Enables or disables scroll end effect in response to vertical overscroll. 809// Set the value to '1' to enable the feature, and set to '0' to disable. 810// Defaults to disabled. 811const char kScrollEndEffect[] = "scroll-end-effect"; 812 813// Visibly render a border around paint rects in the web page to help debug 814// and study painting behavior. 815const char kShowPaintRects[] = "show-paint-rects"; 816 817// Map mouse input events into touch gesture events. Useful for debugging touch 818// gestures without needing a touchscreen. 819const char kSimulateTouchScreenWithMouse[] = 820 "simulate-touch-screen-with-mouse"; 821 822// Runs the renderer and plugins in the same process as the browser 823const char kSingleProcess[] = "single-process"; 824 825// Experimentally enforces a one-site-per-process security policy. 826// All cross-site navigations force process swaps, and we can restrict a 827// renderer process's access rights based on its site. For details, see: 828// http://www.chromium.org/developers/design-documents/site-isolation 829// 830// Unlike --enable-strict-site-isolation (which allows cross-site iframes), 831// this flag does not affect which cookies are attached to cross-site requests. 832// Support is being added to render cross-site iframes in a different process 833// than their parent pages. 834const char kSitePerProcess[] = "site-per-process"; 835 836// Skip gpu info collection, blacklist loading, and blacklist auto-update 837// scheduling at browser startup time. 838// Therefore, all GPU features are available, and about:gpu page shows empty 839// content. The switch is intended only for layout tests. 840// TODO(gab): Get rid of this switch entirely. 841const char kSkipGpuDataLoading[] = "skip-gpu-data-loading"; 842 843// Specifies the request key for the continuous speech recognition webservice. 844const char kSpeechRecognitionWebserviceKey[] = "speech-service-key"; 845 846// Specifies if the |StatsCollectionController| needs to be bound in the 847// renderer. This binding happens on per-frame basis and hence can potentially 848// be a performance bottleneck. One should only enable it when running a test 849// that needs to access the provided statistics. 850const char kStatsCollectionController[] = 851 "enable-stats-collection-bindings"; 852 853// Upscale defaults to "good". 854const char kTabCaptureDownscaleQuality[] = "tab-capture-downscale-quality"; 855 856// Scaling quality for capturing tab. Should be one of "fast", "good" or "best". 857// One flag for upscaling, one for downscaling. 858// Upscale defaults to "best". 859const char kTabCaptureUpscaleQuality[] = "tab-capture-upscale-quality"; 860 861// Allows for forcing socket connections to http/https to use fixed ports. 862const char kTestingFixedHttpPort[] = "testing-fixed-http-port"; 863const char kTestingFixedHttpsPort[] = "testing-fixed-https-port"; 864 865// Runs the security test for the renderer sandbox. 866const char kTestSandbox[] = "test-sandbox"; 867 868// Enable timeout-based touch event cancellation if a touch ack is delayed. 869// If unspecified, touch timeout behavior will be disabled. 870const char kTouchAckTimeoutDelayMs[] = "touch-ack-timeout-delay-ms"; 871 872// Causes TRACE_EVENT flags to be recorded beginning with shutdown. Optionally, 873// can specify the specific trace categories to include (e.g. 874// --trace-shutdown=base,net) otherwise, all events are recorded. 875// --trace-shutdown-file can be used to control where the trace log gets stored 876// to since there is otherwise no way to access the result. 877const char kTraceShutdown[] = "trace-shutdown"; 878 879// If supplied, sets the file which shutdown tracing will be stored into, if 880// omitted the default will be used "chrometrace.log" in the current directory. 881// Has no effect unless --trace-shutdown is also supplied. 882// Example: --trace-shutdown --trace-shutdown-file=/tmp/trace_event.log 883const char kTraceShutdownFile[] = "trace-shutdown-file"; 884 885// Causes TRACE_EVENT flags to be recorded from startup. Optionally, can 886// specify the specific trace categories to include (e.g. 887// --trace-startup=base,net) otherwise, all events are recorded. Setting this 888// flag results in the first call to BeginTracing() to receive all trace events 889// since startup. In Chrome, you may find --trace-startup-file and 890// --trace-startup-duration to control the auto-saving of the trace (not 891// supported in the base-only TraceLog component). 892const char kTraceStartup[] = "trace-startup"; 893 894// Sets the time in seconds until startup tracing ends. If omitted a default of 895// 5 seconds is used. Has no effect without --trace-startup, or if 896// --startup-trace-file=none was supplied. 897const char kTraceStartupDuration[] = "trace-startup-duration"; 898 899// If supplied, sets the file which startup tracing will be stored into, if 900// omitted the default will be used "chrometrace.log" in the current directory. 901// Has no effect unless --trace-startup is also supplied. 902// Example: --trace-startup --trace-startup-file=/tmp/trace_event.log 903// As a special case, can be set to 'none' - this disables automatically saving 904// the result to a file and the first manually recorded trace will then receive 905// all events since startup. 906const char kTraceStartupFile[] = "trace-startup-file"; 907 908 909 910// Prioritizes the UI's command stream in the GPU process 911extern const char kUIPrioritizeInGpuProcess[] = 912 "ui-prioritize-in-gpu-process"; 913 914// Use fake device for MediaStream to replace actual camera and microphone. 915const char kUseFakeDeviceForMediaStream[] = "use-fake-device-for-media-stream"; 916 917// Bypass the media stream infobar by selecting the default device for media 918// streams (e.g. WebRTC). Works with --use-fake-device-for-media-stream. 919const char kUseFakeUIForMediaStream[] = "use-fake-ui-for-media-stream"; 920 921// Use hardware gpu, if available, for tests. 922const char kUseGpuInTests[] = "use-gpu-in-tests"; 923 924// Set when Chromium should use a mobile user agent. 925const char kUseMobileUserAgent[] = "use-mobile-user-agent"; 926 927// A string used to override the default user agent with a custom one. 928const char kUserAgent[] = "user-agent"; 929 930// On POSIX only: the contents of this flag are prepended to the utility 931// process command line. Useful values might be "valgrind" or "xterm -e gdb 932// --args". 933const char kUtilityCmdPrefix[] = "utility-cmd-prefix"; 934 935// Causes the process to run as a utility subprocess. 936const char kUtilityProcess[] = "utility"; 937 938// The utility process is sandboxed, with access to one directory. This flag 939// specifies the directory that can be accessed. 940const char kUtilityProcessAllowedDir[] = "utility-allowed-dir"; 941 942// Allows MDns to access network in sandboxed process. 943const char kUtilityProcessEnableMDns[] = "utility-enable-mdns"; 944 945// Will add kWaitForDebugger to every child processes. If a value is passed, it 946// will be used as a filter to determine if the child process should have the 947// kWaitForDebugger flag passed on or not. 948const char kWaitForDebuggerChildren[] = "wait-for-debugger-children"; 949 950// Choose which logging channels in WebCore to activate. See 951// Logging.cpp in WebKit's WebCore for a list of available channels. 952const char kWebCoreLogChannels[] = "webcore-log-channels"; 953 954// Overrides the amount of shared memory the webgl command buffer allocates 955const char kWebGLCommandBufferSizeKb[] = "webgl-command-buffer-size-kb"; 956 957// Causes the process to run as a worker subprocess. 958const char kWorkerProcess[] = "worker"; 959 960// The prefix used when starting the zygote process. (i.e. 'gdb --args') 961const char kZygoteCmdPrefix[] = "zygote-cmd-prefix"; 962 963// Causes the process to run as a renderer zygote. 964const char kZygoteProcess[] = "zygote"; 965 966#if defined(ENABLE_WEBRTC) 967// Enables audio processing in a MediaStreamTrack. When this flag is on, AEC, 968// NS and AGC will be done per MediaStreamTrack instead of in PeerConnection. 969const char kEnableAudioTrackProcessing[] = "enable-audio-track-processing"; 970 971// Disables WebRTC device enumeration. 972const char kDisableDeviceEnumeration[] = "disable-device-enumeration"; 973 974// Disables WebRTC DataChannels SCTP wire protocol support. 975const char kDisableSCTPDataChannels[] = "disable-sctp-data-channels"; 976 977// Disables HW decode acceleration for WebRTC. 978const char kDisableWebRtcHWDecoding[] = "disable-webrtc-hw-decoding"; 979 980// Disables encryption of RTP Media for WebRTC. When Chrome embeds Content, it 981// ignores this switch on its stable and beta channels. 982const char kDisableWebRtcEncryption[] = "disable-webrtc-encryption"; 983 984// Disables HW encode acceleration for WebRTC. 985const char kDisableWebRtcHWEncoding[] = "disable-webrtc-hw-encoding"; 986 987// Enables WebRTC AEC recordings. 988const char kEnableWebRtcAecRecordings[] = "enable-webrtc-aec-recordings"; 989 990// Enables WebRTC to open TCP server sockets. 991const char kEnableWebRtcTcpServerSocket[] = "enable-webrtc-tcp-server-socket"; 992 993// Enables VP8 HW encode acceleration for WebRTC. 994const char kEnableWebRtcHWVp8Encoding[] = "enable-webrtc-hw-vp8-encoding"; 995#endif 996 997#if defined(OS_ANDROID) 998// Disable user gesture requirement for the media element to enter fullscreen. 999const char kDisableGestureRequirementForMediaFullscreen[] = 1000 "disable-gesture-requirement-for-media-fullscreen"; 1001 1002// Disable user gesture requirement for media playback. 1003const char kDisableGestureRequirementForMediaPlayback[] = 1004 "disable-gesture-requirement-for-media-playback"; 1005 1006// Disable history logging for media elements. 1007const char kDisableMediaHistoryLogging[] = "disable-media-history"; 1008 1009// Disable overscroll edge effects like those found in Android views. 1010const char kDisableOverscrollEdgeEffect[] = "disable-overscroll-edge-effect"; 1011 1012// WebRTC is enabled by default on Android. 1013const char kDisableWebRTC[] = "disable-webrtc"; 1014 1015// Enable the recognition part of the Web Speech API. 1016const char kEnableSpeechRecognition[] = "enable-speech-recognition"; 1017 1018// Don't display any scrollbars. This is useful for Android WebView where 1019// the system manages the scrollbars instead. 1020const char kHideScrollbars[] = "hide-scrollbars"; 1021 1022// The telephony region (ISO country code) to use in phone number detection. 1023const char kNetworkCountryIso[] = "network-country-iso"; 1024 1025// Enables remote debug over HTTP on the specified socket name. 1026const char kRemoteDebuggingSocketName[] = "remote-debugging-socket-name"; 1027#endif 1028 1029#if defined(OS_ANDROID) && defined(ARCH_CPU_X86) 1030const char kEnableWebAudio[] = "enable-webaudio"; 1031#else 1032// Disable web audio API. 1033const char kDisableWebAudio[] = "disable-webaudio"; 1034#endif 1035 1036#if defined(OS_CHROMEOS) 1037// Disables panel fitting (used for mirror mode). 1038const char kDisablePanelFitting[] = "disable-panel-fitting"; 1039#endif 1040 1041#if defined(OS_MACOSX) && !defined(OS_IOS) 1042const char kDisableCarbonInterposing[] = "disable-carbon-interposing"; 1043 1044// Disables support for Core Animation plugins. This is triggered when 1045// accelerated compositing is disabled. See http://crbug.com/122430 . 1046const char kDisableCoreAnimationPlugins[] = 1047 "disable-core-animation-plugins"; 1048 1049// Use core animation to draw the RenderWidgetHostView on Mac. 1050const char kUseCoreAnimation[] = "use-core-animation"; 1051#endif 1052 1053#if defined(OS_POSIX) 1054// Causes the child processes to cleanly exit via calling exit(). 1055const char kChildCleanExit[] = "child-clean-exit"; 1056#endif 1057 1058// Don't dump stuff here, follow the same order as the header. 1059 1060} // namespace switches 1061