2 * Copyright (C) 2007, 2008, 2009 Apple 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
8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright
11 * notice, this list of conditions and the following disclaimer in the
12 * documentation and/or other materials provided with the distribution.
13 * 3. Neither the name of Apple Inc. ("Apple") nor the names of
14 * its contributors may be used to endorse or promote products derived
15 * from this software without specific prior written permission.
17 * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
18 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
19 * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
20 * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
21 * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
22 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
24 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
34 typedef enum WebKitJavaScriptRuntimeFlags {
35 WebKitJavaScriptRuntimeFlagsAllEnabled = 0
36 } WebKitJavaScriptRuntimeFlags;
42 uuid(1380DE41-42CF-4170-9D5D-7840EDE5B36C),
43 pointer_default(unique)
45 interface IWebPreferencesPrivate : IUnknown
47 HRESULT setDeveloperExtrasEnabled([in] BOOL enabled);
48 HRESULT developerExtrasEnabled([out, retval] BOOL* enabled);
50 HRESULT setAutomaticallyDetectsCacheModel([in] BOOL automaticallyDetectsCacheModel);
51 HRESULT automaticallyDetectsCacheModel([out, retval] BOOL* automaticallyDetectsCacheModel);
53 HRESULT setAuthorAndUserStylesEnabled([in] BOOL enabled);
54 HRESULT authorAndUserStylesEnabled([out, retval] BOOL* enabled);
56 HRESULT inApplicationChromeMode([out, retval] BOOL *allowed);
57 HRESULT setApplicationChromeMode([in] BOOL allowed);
59 HRESULT setOfflineWebApplicationCacheEnabled([in] BOOL enabled);
60 HRESULT offlineWebApplicationCacheEnabled([out, retval] BOOL *enabled);
62 HRESULT localStorageDatabasePath([out, retval] BSTR* location);
63 HRESULT setLocalStorageDatabasePath([in] BSTR location);
65 // These two methods are no-ops, and only retained to keep
66 // the Interface consistent. DO NOT USE THEM.
67 HRESULT setShouldPaintNativeControls([in] BOOL shouldPaint);
68 HRESULT shouldPaintNativeControls([out, retval] BOOL* enabled);
70 HRESULT setDatabasesEnabled([in] BOOL enabled);
71 HRESULT databasesEnabled([out, retval] BOOL *enabled);
73 HRESULT setLocalStorageEnabled([in] BOOL enabled);
74 HRESULT localStorageEnabled([out, retval] BOOL* enabled);
76 HRESULT setFontSmoothingContrast([in] float contrast);
77 HRESULT fontSmoothingContrast([out, retval] float* contrast);
79 HRESULT isWebSecurityEnabled([out, retval] BOOL* enabled);
80 HRESULT setWebSecurityEnabled([in] BOOL enabled);
82 HRESULT allowUniversalAccessFromFileURLs([out, retval] BOOL *allowAccess);
83 HRESULT setAllowUniversalAccessFromFileURLs([in] BOOL allowAccess);
85 HRESULT isXSSAuditorEnabled([out, retval] BOOL *enabled);
86 HRESULT setXSSAuditorEnabled([in] BOOL enabled);
88 HRESULT isFrameFlatteningEnabled([out, retval] BOOL *enabled);
89 HRESULT setFrameFlatteningEnabled([in] BOOL enabled);
91 HRESULT experimentalNotificationsEnabled([out, retval] BOOL *enabled);
92 HRESULT setExperimentalNotificationsEnabled([in] BOOL enabled);
94 HRESULT setShouldUseHighResolutionTimers([in] BOOL useHighResolutionTimers);
95 HRESULT shouldUseHighResolutionTimers([out, retval] BOOL* useHighResolutionTimers);
97 // Used to set preference specified by a test via TestRunner.overridePreference(..).
98 // Used by DumpRenderTree.
99 HRESULT setPreferenceForTest([in] BSTR key, [in] BSTR value);
104 HRESULT setAcceleratedCompositingEnabled([in] BOOL);
105 HRESULT acceleratedCompositingEnabled([out, retval] BOOL*);
107 HRESULT setCustomDragCursorsEnabled([in] BOOL);
108 HRESULT customDragCursorsEnabled([out, retval] BOOL*);
110 HRESULT allowFileAccessFromFileURLs([out, retval] BOOL *allowAccess);
111 HRESULT setAllowFileAccessFromFileURLs([in] BOOL allowAccess);
113 HRESULT setShowDebugBorders([in] BOOL);
114 HRESULT showDebugBorders([out, retval] BOOL*);
116 HRESULT setShowRepaintCounter([in] BOOL);
117 HRESULT showRepaintCounter([out, retval] BOOL*);
119 HRESULT javaScriptCanAccessClipboard([out, retval] BOOL *enabled);
120 HRESULT setJavaScriptCanAccessClipboard([in] BOOL enabled);
122 HRESULT isDNSPrefetchingEnabled([out, retval] BOOL *enabled);
123 HRESULT setDNSPrefetchingEnabled([in] BOOL enabled);
125 HRESULT hyperlinkAuditingEnabled(BOOL *hyperlinkAuditingEnabled);
126 HRESULT setHyperlinkAuditingEnabled(BOOL hyperlinkAuditingEnabled);
128 HRESULT setLoadsSiteIconsIgnoringImageLoadingPreference([in] BOOL enabled);
129 HRESULT loadsSiteIconsIgnoringImageLoadingPreference([out, retval] BOOL* enabled);
131 HRESULT setFullScreenEnabled([in] BOOL enabled);
132 HRESULT isFullScreenEnabled([out, retval] BOOL* enabled);
134 HRESULT setHixie76WebSocketProtocolEnabled([in] BOOL enabled);
135 HRESULT hixie76WebSocketProtocolEnabled([out, retval] BOOL* enabled);
137 HRESULT setMediaPlaybackRequiresUserGesture([in] BOOL);
138 HRESULT mediaPlaybackRequiresUserGesture([out, retval] BOOL*);
140 HRESULT setMediaPlaybackAllowsInline([in] BOOL);
141 HRESULT mediaPlaybackAllowsInline([out, retval] BOOL*);
143 HRESULT setShowsToolTipOverTruncatedText([in] BOOL);
144 HRESULT showsToolTipOverTruncatedText([out, retval] BOOL*);
146 HRESULT setShouldInvertColors([in] BOOL);
147 HRESULT shouldInvertColors([out, retval] BOOL*);
149 HRESULT setRequestAnimationFrameEnabled([in] BOOL);
150 HRESULT requestAnimationFrameEnabled([out, retval] BOOL*);
152 HRESULT mockScrollbarsEnabled([out, retval] BOOL* enabled);
153 HRESULT setMockScrollbarsEnabled([in] BOOL enabled);
155 // These two methods are no-ops, and only retained to keep
156 // the Interface consistent. DO NOT USE THEM.
157 HRESULT screenFontSubstitutionEnabled([out, retval] BOOL* enabled);
158 HRESULT setScreenFontSubstitutionEnabled([in] BOOL enabled);
160 HRESULT isInheritURIQueryComponentEnabled([out, retval] BOOL* enabled);
161 HRESULT setEnableInheritURIQueryComponent([in] BOOL enabled);
164 [ uuid(0E1DDB80-6B38-4ABC-A252-B58A83EB6D8C) ]
165 interface IWebPreferencesPrivate2 : IWebPreferencesPrivate
167 HRESULT javaScriptRuntimeFlags([out, retval] unsigned* flags);
168 HRESULT setJavaScriptRuntimeFlags([in] unsigned flags);
169 HRESULT allowDisplayAndRunningOfInsecureContent([out, retval] BOOL* enabled);
170 HRESULT setAllowDisplayAndRunningOfInsecureContent([in] BOOL enabled);
173 [uuid(92809BFB-C24F-43AD-863F-601B08CC268D)]
174 interface IWebPreferencesPrivate3 : IWebPreferencesPrivate2
176 HRESULT showTiledScrollingIndicator([out, retval] BOOL* enabled);
177 HRESULT setShowTiledScrollingIndicator([in] BOOL enabled);
178 HRESULT domIteratorEnabled([out, retval] BOOL* enabled);
179 HRESULT setDOMIteratorEnabled([in] BOOL enabled);
180 HRESULT fetchAPIEnabled([out, retval] BOOL* enabled);
181 HRESULT setFetchAPIEnabled([in] BOOL enabled);
182 HRESULT shadowDOMEnabled([out, retval] BOOL* enabled);
183 HRESULT setShadowDOMEnabled([in] BOOL enabled);
184 HRESULT customElementsEnabled([out, retval] BOOL* enabled);
185 HRESULT setCustomElementsEnabled([in] BOOL enabled);
186 HRESULT modernMediaControlsEnabled([out, retval] BOOL* enabled);
187 HRESULT setModernMediaControlsEnabled([in] BOOL enabled);
188 HRESULT es6ModulesEnabled([out, retval] BOOL* enabled);
189 HRESULT setES6ModulesEnabled([in] BOOL enabled);
192 [uuid(F9582D72-6348-45B1-AB09-39E33459B5B9)]
193 interface IWebPreferencesPrivate4 : IWebPreferencesPrivate3
195 HRESULT setApplicationId([in] BSTR applicationId);