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