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