2 * Copyright (C) 2013 Google Inc. All rights reserved.
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are
8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above
11 * copyright notice, this list of conditions and the following disclaimer
12 * in the documentation and/or other materials provided with the
14 * * Neither the name of Google Inc. nor the names of its
15 * contributors may be used to endorse or promote products derived from
16 * this software without specific prior written permission.
18 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
21 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 #ifndef WebRuntimeFeatures_h
32 #define WebRuntimeFeatures_h
34 #include "../platform/WebCommon.h"
38 // This class is used to enable runtime features of Blink.
39 // Stable features are enabled by default.
40 class WebRuntimeFeatures {
42 BLINK_EXPORT static void enableExperimentalFeatures(bool);
43 BLINK_EXPORT static void enableTestOnlyFeatures(bool);
45 BLINK_EXPORT static void enableApplicationCache(bool);
47 BLINK_EXPORT static void enableDatabase(bool);
49 BLINK_EXPORT static void enableCompositedSelectionUpdate(bool);
50 BLINK_EXPORT static bool isCompositedSelectionUpdateEnabled();
52 BLINK_EXPORT static void enableDecodeToYUV(bool);
54 BLINK_EXPORT static void enableDisplayList2dCanvas(bool);
55 BLINK_EXPORT static void forceDisplayList2dCanvas(bool);
57 BLINK_EXPORT static void enableEncryptedMedia(bool);
58 BLINK_EXPORT static bool isEncryptedMediaEnabled();
60 BLINK_EXPORT static void enablePrefixedEncryptedMedia(bool);
61 BLINK_EXPORT static bool isPrefixedEncryptedMediaEnabled();
63 BLINK_EXPORT static void enableBleedingEdgeFastPaths(bool);
65 BLINK_EXPORT static void enableBlinkScheduler(bool);
67 BLINK_EXPORT static void enableExperimentalCanvasFeatures(bool);
69 BLINK_EXPORT static void enableFastMobileScrolling(bool);
71 BLINK_EXPORT static void enableFileSystem(bool);
73 BLINK_EXPORT static void enableImageColorProfiles(bool);
75 BLINK_EXPORT static void enableLocalStorage(bool);
77 BLINK_EXPORT static void enableMediaPlayer(bool);
79 BLINK_EXPORT static void enableSubpixelFontScaling(bool);
81 BLINK_EXPORT static void enableMediaCapture(bool);
83 BLINK_EXPORT static void enableMediaSource(bool);
85 BLINK_EXPORT static void enableNotifications(bool);
87 BLINK_EXPORT static void enableNavigatorContentUtils(bool);
89 BLINK_EXPORT static void enableNavigationTransitions(bool);
91 BLINK_EXPORT static void enableNetworkInformation(bool);
93 BLINK_EXPORT static void enableOrientationEvent(bool);
95 BLINK_EXPORT static void enablePagePopup(bool);
97 BLINK_EXPORT static void enablePeerConnection(bool);
99 BLINK_EXPORT static void enableRequestAutocomplete(bool);
101 BLINK_EXPORT static void enableScreenOrientation(bool);
103 BLINK_EXPORT static void enableScriptedSpeech(bool);
105 BLINK_EXPORT static void enableServiceWorker(bool);
107 BLINK_EXPORT static void enableSessionStorage(bool);
109 BLINK_EXPORT static void enableSlimmingPaint(bool);
111 BLINK_EXPORT static void enableTouch(bool);
113 BLINK_EXPORT static void enableTouchIconLoading(bool);
115 BLINK_EXPORT static void enableWebAudio(bool);
117 BLINK_EXPORT static void enableWebGLDraftExtensions(bool);
119 BLINK_EXPORT static void enableWebGLImageChromium(bool);
121 BLINK_EXPORT static void enableWebMIDI(bool);
123 BLINK_EXPORT static void enableXSLT(bool);
125 BLINK_EXPORT static void enableOverlayScrollbars(bool);
127 BLINK_EXPORT static void enableOverlayFullscreenVideo(bool);
129 BLINK_EXPORT static void enableSharedWorker(bool);
131 BLINK_EXPORT static void enablePreciseMemoryInfo(bool);
133 BLINK_EXPORT static void enableLayerSquashing(bool);
135 BLINK_EXPORT static void enableShowModalDialog(bool);
137 BLINK_EXPORT static void enableLaxMixedContentChecking(bool);
139 BLINK_EXPORT static void enableCredentialManagerAPI(bool);
141 BLINK_EXPORT static void enableTextBlobs(bool);
143 BLINK_EXPORT static void enableCSSViewport(bool);
145 BLINK_EXPORT static void enableV8IdleTasks(bool);
147 BLINK_EXPORT static void enableSVG1DOM(bool);
150 WebRuntimeFeatures();