OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 17 matching lines...) Expand all Loading... |
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
29 */ | 29 */ |
30 | 30 |
31 #ifndef WebRuntimeFeatures_h | 31 #ifndef WebRuntimeFeatures_h |
32 #define WebRuntimeFeatures_h | 32 #define WebRuntimeFeatures_h |
33 | 33 |
34 #include "../platform/WebCommon.h" | 34 #include "../platform/WebCommon.h" |
35 | 35 |
36 namespace WebKit { | 36 namespace WebKit { |
37 | 37 |
| 38 class WebString; |
| 39 |
38 // This class is used to enable runtime features of Blink. | 40 // This class is used to enable runtime features of Blink. |
39 // All features are disabled by default. | 41 // All features are disabled by default. |
40 // Most clients should call enableStableFeatures() to enable | 42 // Most clients should call enableStableFeatures() to enable |
41 // features Blink has made API commitments to. | 43 // features Blink has made API commitments to. |
42 class WebRuntimeFeatures { | 44 class WebRuntimeFeatures { |
43 public: | 45 public: |
44 WEBKIT_EXPORT static void enableStableFeatures(bool); | 46 WEBKIT_EXPORT static void enableStableFeatures(bool); |
45 WEBKIT_EXPORT static void enableExperimentalFeatures(bool); | 47 WEBKIT_EXPORT static void enableExperimentalFeatures(bool); |
46 WEBKIT_EXPORT static void enableTestOnlyFeatures(bool); | 48 WEBKIT_EXPORT static void enableTestOnlyFeatures(bool); |
| 49 WEBKIT_EXPORT static bool setFeatureEnabled(const WebString&, bool); |
47 | 50 |
48 // FIXME: Delete after removing all callers in Content. | 51 // FIXME: Delete after removing all callers in Content. |
49 static void enableFullScreenAPI(bool enable) { enableFullscreen(enable); } | 52 static void enableFullScreenAPI(bool enable) { enableFullscreen(enable); } |
50 static void enableIndexedDatabase(bool enable) { enableIndexedDB(enable); } | 53 static void enableIndexedDatabase(bool enable) { enableIndexedDB(enable); } |
51 | 54 |
52 WEBKIT_EXPORT static void enableApplicationCache(bool); | 55 WEBKIT_EXPORT static void enableApplicationCache(bool); |
53 WEBKIT_EXPORT static bool isApplicationCacheEnabled(); | 56 WEBKIT_EXPORT static bool isApplicationCacheEnabled(); |
54 | 57 |
55 WEBKIT_EXPORT static void enableCanvasPath(bool); | 58 WEBKIT_EXPORT static void enableCanvasPath(bool); |
56 WEBKIT_EXPORT static bool isCanvasPathEnabled(); | 59 WEBKIT_EXPORT static bool isCanvasPathEnabled(); |
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
208 WEBKIT_EXPORT static void enableInputTypeColor(bool); | 211 WEBKIT_EXPORT static void enableInputTypeColor(bool); |
209 WEBKIT_EXPORT static bool isInputTypeColorEnabled(); | 212 WEBKIT_EXPORT static bool isInputTypeColorEnabled(); |
210 | 213 |
211 private: | 214 private: |
212 WebRuntimeFeatures(); | 215 WebRuntimeFeatures(); |
213 }; | 216 }; |
214 | 217 |
215 } // namespace WebKit | 218 } // namespace WebKit |
216 | 219 |
217 #endif | 220 #endif |
OLD | NEW |