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