Changeset 224077 in webkit
- Timestamp:
- Oct 26, 2017 6:45:28 PM (6 years ago)
- Location:
- trunk/Source/WebKit
- Files:
-
- 14 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/CMakeLists.txt
r224041 r224077 908 908 909 909 set(WebKit_WEB_PREFERENCES_TEMPLATES 910 ${WEBKIT_DIR}/Scripts/PreferencesTemplates/WebPageUpdatePreferences.cpp.erb 910 911 ${WEBKIT_DIR}/Scripts/PreferencesTemplates/WebPreferencesDefinitions.h.erb 911 912 ) 912 913 913 914 add_custom_command( 914 OUTPUT ${DERIVED_SOURCES_WEBKIT_DIR}/WebP referencesDefinitions.h915 OUTPUT ${DERIVED_SOURCES_WEBKIT_DIR}/WebPageUpdatePreferences.cpp ${DERIVED_SOURCES_WEBKIT_DIR}/WebPreferencesDefinitions.h 915 916 MAIN_DEPENDENCY ${WEBKIT_DIR}/Shared/WebPreferences.yaml 916 917 DEPENDS ${WebKit_WEB_PREFERENCES_TEMPLATES} … … 921 922 ${DERIVED_SOURCES_WEBKIT_DIR}/WebPreferencesDefinitions.h 922 923 ) 924 925 list(APPEND WebKit_SOURCES 926 ${DERIVED_SOURCES_WEBKIT_DIR}/WebPageUpdatePreferences.cpp 927 ) 928 923 929 924 930 list(APPEND WebKit_SOURCES ${WebKit_DERIVED_SOURCES}) -
trunk/Source/WebKit/ChangeLog
r224071 r224077 1 2017-10-26 Sam Weinig <sam@webkit.org> 2 3 [Settings] Generate the bulk of WebPage::updatePreferences(...) 4 https://bugs.webkit.org/show_bug.cgi?id=178823 5 6 Reviewed by Tim Horton. 7 8 * CMakeLists.txt: 9 * DerivedSources.make: 10 * WebKit.xcodeproj/project.pbxproj: 11 12 Add new file generation. 13 14 * Scripts/GeneratePreferences.rb: 15 16 Replace 'webkitOnly' boolean option with a new 'webcoreBinding' option. 17 'webcoreBinding' supports the following values: 18 - none (same as webkit only) 19 - custom (means that you do bind to a webcore concept, but currently it must 20 be done in a custom manner) 21 - DeprecatedGlobalSettings (binds to a DeprecatedGlobalSettings setting) 22 - RuntimeEnabledFeatures (binds to a RuntimeEnabledFeatures setting) 23 If 'webcoreBinding' is not provided, the preference binds to WebCore Setting 24 of either the same name or the override name provided by the new 'webcoreName' 25 option (we should try to remove the need for 'webcoreName' by unifying with 26 WebCore on preference/setting naming). 27 28 A 'condition' option was also added to indicate that the preference is only available 29 when that macro condition is true. 30 31 Since we are generating most of WebPage::updatePreferences, we can simplify the 32 macros in WebPreferencesDefinitions.h to only have normal/debug/experimental variants 33 and remove the need for per-type macros, which were only used in WebPage::updatePreferences. 34 35 * Scripts/PreferencesTemplates/WebPageUpdatePreferences.cpp.erb: Added. 36 37 Generates bindings from WebPreferences to WebCore::Settings/DeprecatedGlobalSettings/RuntimeEnabledFeatures. 38 Does not generate a binding if the 'webcoreBinding' option is set to either 'none' or 'custom'. 39 40 * Scripts/PreferencesTemplates/WebPreferencesDefinitions.h.erb: 41 42 Simplify down to just normal/debug/experimental macros. 43 44 * Shared/WebPreferences.yaml: 45 46 Annotate perferences with new optional 'webcoreBinding', 'webcoreName', and 'condition' 47 options. 48 49 * WebProcess/WebPage/WebPage.cpp: 50 (WebKit::WebPage::updatePreferences): 51 52 Replace a ton of hand written preference to settings bindings with a call to updatePreferencesGenerated(). 53 54 * WebProcess/WebPage/WebPage.h: 55 56 Add declaration of updatePreferencesGenerated, remove platformPreferencesDidChange. 57 58 * WebProcess/WebPage/gtk/WebPageGtk.cpp: 59 (WebKit::WebPage::platformPreferencesDidChange): Deleted. 60 * WebProcess/WebPage/ios/WebPageIOS.mm: 61 (WebKit::WebPage::platformPreferencesDidChange): Deleted. 62 * WebProcess/WebPage/mac/WebPageMac.mm: 63 (WebKit::WebPage::platformPreferencesDidChange): Deleted. 64 * WebProcess/WebPage/win/WebPageWin.cpp: 65 (WebKit::WebPage::platformPreferencesDidChange): Deleted. 66 * WebProcess/WebPage/wpe/WebPageWPE.cpp: 67 (WebKit::WebPage::platformPreferencesDidChange): Deleted. 68 69 Remove all the empty platformPreferencesDidChange functions. 70 1 71 2017-10-26 Alex Christensen <achristensen@webkit.org> 2 72 -
trunk/Source/WebKit/DerivedSources.make
r224041 r224077 289 289 290 290 WEB_PREFERENCES_TEMPLATES = \ 291 $(WebKit2)/Scripts/PreferencesTemplates/WebPageUpdatePreferences.cpp.erb \ 291 292 $(WebKit2)/Scripts/PreferencesTemplates/WebPreferencesDefinitions.h.erb \ 292 293 # 293 294 294 all : WebPreferencesDefinitions.h 295 296 WebPreferencesDefinitions%h : $(WebKit2)/Scripts/GeneratePreferences.rb $(WEB_PREFERENCES_TEMPLATES) $(WebKit2)/Shared/WebPreferences.yaml295 all : WebPreferencesDefinitions.h WebPageUpdatePreferences.cpp 296 297 WebPreferencesDefinitions%h WebPageUpdatePreferences%cpp: $(WebKit2)/Scripts/GeneratePreferences.rb $(WEB_PREFERENCES_TEMPLATES) $(WebKit2)/Shared/WebPreferences.yaml 297 298 $(RUBY) $< --input $(WebKit2)/Shared/WebPreferences.yaml 298 299 -
trunk/Source/WebKit/Scripts/GeneratePreferences.rb
r223903 r224077 68 68 attr_accessor :humanReadableName 69 69 attr_accessor :humanReadableDescription 70 attr_accessor :webkitOnly71 70 attr_accessor :category 71 attr_accessor :webcoreBinding 72 attr_accessor :condition 72 73 73 74 def initialize(name, opts) … … 77 78 @humanReadableName = '"' + (opts["humanReadableName"] || "") + '"' 78 79 @humanReadableDescription = '"' + (opts["humanReadableDescription"] || "") + '"' 79 @webkitOnly = opts["webkitOnly"]80 80 @category = opts["category"] 81 81 @getter = opts["getter"] 82 @webcoreBinding = opts["webcoreBinding"] 83 @webcoreName = opts["webcoreName"] 84 @condition = opts["condition"] 82 85 end 83 86 … … 93 96 end 94 97 end 98 99 def webcoreNameUpper 100 if @webcoreName 101 @webcoreName[0].upcase + @webcoreName[1..@webcoreName.length] 102 else 103 @name 104 end 105 end 106 107 def typeUpper 108 if @type == "uint32_t" 109 "UInt32" 110 else 111 @type.capitalize 112 end 113 end 114 95 115 end 96 116 … … 115 135 @preferences.sort! { |x, y| x.name <=> y.name } 116 136 117 @boolPreferencesNotDebug = @preferences.select { |p| !p.category && !p.webkitOnly && p.type == "bool" } 118 @doublePreferencesNotDebug = @preferences.select { |p| !p.category && !p.webkitOnly && p.type == "double" } 119 @intPreferencesNotDebug = @preferences.select { |p| !p.category && !p.webkitOnly && p.type == "uint32_t" } 120 @stringPreferencesNotDebug = @preferences.select { |p| !p.category && !p.webkitOnly && p.type == "String" } 121 @stringPreferencesNotDebugNotInWebKit = @preferences.select { |p| !p.category && p.webkitOnly && p.type == "String" } 137 @preferencesNotDebug = @preferences.select { |p| !p.category } 138 @preferencesDebug = @preferences.select { |p| p.category == "debug" } 139 @experimentalFeatures = @preferences.select { |p| p.category == "experimental" } 122 140 123 @boolPreferencesDebug = @preferences.select { |p| p.category == "debug" && !p.webkitOnly && p.type == "bool" } 124 @intPreferencesDebug = @preferences.select { |p| p.category == "debug" && !p.webkitOnly && p.type == "uint32_t" } 125 126 @experimentalFeature = @preferences.select { |p| p.category == "experimental" && !p.webkitOnly } 141 @preferencesBoundToSetting = @preferences.select { |p| !p.webcoreBinding } 142 @preferencesBoundToDeprecatedGlobalSettings = @preferences.select { |p| p.webcoreBinding == "DeprecatedGlobalSettings" } 143 @preferencesBoundToRuntimeEnabledFeatures = @preferences.select { |p| p.webcoreBinding == "RuntimeEnabledFeatures" } 127 144 end 128 145 … … 139 156 preferences = Preferences.new(parsedPreferences) 140 157 preferences.renderToFile("PreferencesTemplates/WebPreferencesDefinitions.h.erb", File.join(options[:outputDirectory], "WebPreferencesDefinitions.h")) 158 preferences.renderToFile("PreferencesTemplates/WebPageUpdatePreferences.cpp.erb", File.join(options[:outputDirectory], "WebPageUpdatePreferences.cpp")) -
trunk/Source/WebKit/Scripts/PreferencesTemplates/WebPageUpdatePreferences.cpp.erb
r224076 r224077 1 1 /* 2 * Copyright (C) 2014 Igalia S.L. 2 * THIS FILE WAS AUTOMATICALLY GENERATED, DO NOT EDIT. 3 * 4 * Copyright (C) 2017 Apple Inc. All rights reserved. 3 5 * 4 6 * Redistribution and use in source and binary forms, with or without … … 27 29 #include "WebPage.h" 28 30 29 #include "NotImplemented.h"30 31 #include "WebPreferencesKeys.h" 31 32 #include "WebPreferencesStore.h" 33 #include <WebCore/DeprecatedGlobalSettings.h> 34 #include <WebCore/Page.h> 35 #include <WebCore/RuntimeEnabledFeatures.h> 32 36 #include <WebCore/Settings.h> 33 #include <WebCore/SharedBuffer.h>34 35 using namespace WebCore;36 37 37 38 namespace WebKit { 38 39 39 void WebPage:: platformInitialize()40 void WebPage::updatePreferencesGenerated(const WebPreferencesStore& store) 40 41 { 42 WebCore::Settings& settings = m_page->settings(); 43 44 <%- for @pref in @preferencesBoundToSetting do -%> 45 <%- if @pref.condition -%> 46 #if <%= @pref.condition %> 47 <%- end -%> 48 settings.set<%= @pref.webcoreNameUpper %>(store.get<%= @pref.typeUpper %>ValueForKey(WebPreferencesKey::<%= @pref.nameLower %>Key())); 49 <%- if @pref.condition -%> 50 #endif 51 <%- end -%> 52 <%- end -%> 53 54 <%- for @pref in @preferencesBoundToDeprecatedGlobalSettings do -%> 55 <%- if @pref.condition -%> 56 #if <%= @pref.condition %> 57 <%- end -%> 58 WebCore::DeprecatedGlobalSettings::set<%= @pref.webcoreNameUpper %>(store.get<%= @pref.typeUpper %>ValueForKey(WebPreferencesKey::<%= @pref.nameLower %>Key())); 59 <%- if @pref.condition -%> 60 #endif 61 <%- end -%> 62 <%- end -%> 63 64 <%- for @pref in @preferencesBoundToRuntimeEnabledFeatures do -%> 65 <%- if @pref.condition -%> 66 #if <%= @pref.condition %> 67 <%- end -%> 68 WebCore::RuntimeEnabledFeatures::sharedFeatures().set<%= @pref.webcoreNameUpper %>(store.get<%= @pref.typeUpper %>ValueForKey(WebPreferencesKey::<%= @pref.nameLower %>Key())); 69 <%- if @pref.condition -%> 70 #endif 71 <%- end -%> 72 <%- end -%> 41 73 } 42 74 43 void WebPage::platformDetach()44 {45 75 } 46 47 void WebPage::platformEditorState(Frame&, EditorState&, IncludePostLayoutDataHint) const48 {49 notImplemented();50 }51 52 void WebPage::platformPreferencesDidChange(const WebPreferencesStore& store)53 {54 notImplemented();55 }56 57 bool WebPage::performDefaultBehaviorForKeyEvent(const WebKeyboardEvent&)58 {59 notImplemented();60 return false;61 }62 63 bool WebPage::platformHasLocalDataForURL(const URL&)64 {65 notImplemented();66 return false;67 }68 69 String WebPage::cachedResponseMIMETypeForURL(const URL&)70 {71 notImplemented();72 return String();73 }74 75 bool WebPage::platformCanHandleRequest(const ResourceRequest&)76 {77 notImplemented();78 return false;79 }80 81 String WebPage::cachedSuggestedFilenameForURL(const URL&)82 {83 notImplemented();84 return String();85 }86 87 RefPtr<SharedBuffer> WebPage::cachedResponseDataForURL(const URL&)88 {89 notImplemented();90 return nullptr;91 }92 93 String WebPage::platformUserAgent(const URL&) const94 {95 notImplemented();96 return String();97 }98 99 } // namespace WebKit -
trunk/Source/WebKit/Scripts/PreferencesTemplates/WebPreferencesDefinitions.h.erb
r223903 r224077 32 32 // macro(KeyUpper, KeyLower, TypeNameUpper, TypeName, DefaultValue, HumanReadableName, HumanReadableDescription) 33 33 34 #define FOR_EACH_WEBKIT_BOOL_PREFERENCE(macro) \ 35 <%- for @pref in @boolPreferencesNotDebug do -%> 36 macro(<%= @pref.name %>, <%= @pref.nameLower %>, Bool, bool, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 37 <%- end -%> 38 \ 39 40 #define FOR_EACH_WEBKIT_DOUBLE_PREFERENCE(macro) \ 41 <%- for @pref in @doublePreferencesNotDebug do -%> 42 macro(<%= @pref.name %>, <%= @pref.nameLower %>, Double, double, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 43 <%- end -%> 44 \ 45 46 #define FOR_EACH_WEBKIT_UINT32_PREFERENCE(macro) \ 47 <%- for @pref in @intPreferencesNotDebug do -%> 48 macro(<%= @pref.name %>, <%= @pref.nameLower %>, UInt32, uint32_t, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 49 <%- end -%> 50 \ 51 52 #define FOR_EACH_WEBKIT_STRING_PREFERENCE(macro) \ 53 <%- for @pref in @stringPreferencesNotDebug do -%> 54 macro(<%= @pref.name %>, <%= @pref.nameLower %>, String, String, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 55 <%- end -%> 56 \ 57 58 #define FOR_EACH_WEBKIT_STRING_PREFERENCE_NOT_IN_WEBCORE(macro) \ 59 <%- for @pref in @stringPreferencesNotDebugNotInWebKit do -%> 60 macro(<%= @pref.name %>, <%= @pref.nameLower %>, String, String, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 34 #define FOR_EACH_WEBKIT_PREFERENCE(macro) \ 35 <%- for @pref in @preferencesNotDebug do -%> 36 macro(<%= @pref.name %>, <%= @pref.nameLower %>, <%= @pref.typeUpper %>, <%= @pref.type %>, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 61 37 <%- end -%> 62 38 \ … … 65 41 // Debug Preferences 66 42 67 #define FOR_EACH_WEBKIT_DEBUG_BOOL_PREFERENCE(macro) \ 68 <%- for @pref in @boolPreferencesDebug do -%> 69 macro(<%= @pref.name %>, <%= @pref.nameLower %>, Bool, bool, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 70 <%- end -%> 71 \ 72 73 #define FOR_EACH_WEBKIT_DEBUG_UINT32_PREFERENCE(macro) \ 74 <%- for @pref in @intPreferencesDebug do -%> 75 macro(<%= @pref.name %>, <%= @pref.nameLower %>, UInt32, uint32_t, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 43 #define FOR_EACH_WEBKIT_DEBUG_PREFERENCE(macro) \ 44 <%- for @pref in @preferencesDebug do -%> 45 macro(<%= @pref.name %>, <%= @pref.nameLower %>, <%= @pref.typeUpper %>, <%= @pref.type %>, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 76 46 <%- end -%> 77 47 \ … … 81 51 82 52 #define FOR_EACH_WEBKIT_EXPERIMENTAL_FEATURE_PREFERENCE(macro) \ 83 <%- for @pref in @experimentalFeature do -%>53 <%- for @pref in @experimentalFeatures do -%> 84 54 macro(<%= @pref.name %>, <%= @pref.nameLower %>, Bool, bool, <%= @pref.defaultValue %>, <%= @pref.humanReadableName %>, <%= @pref.humanReadableDescription %>) \ 85 55 <%- end -%> 86 56 \ 87 88 89 90 #define FOR_EACH_WEBKIT_DEBUG_PREFERENCE(macro) \91 FOR_EACH_WEBKIT_DEBUG_BOOL_PREFERENCE(macro) \92 FOR_EACH_WEBKIT_DEBUG_UINT32_PREFERENCE(macro) \93 \94 95 #define FOR_EACH_WEBKIT_PREFERENCE(macro) \96 FOR_EACH_WEBKIT_BOOL_PREFERENCE(macro) \97 FOR_EACH_WEBKIT_DOUBLE_PREFERENCE(macro) \98 FOR_EACH_WEBKIT_UINT32_PREFERENCE(macro) \99 FOR_EACH_WEBKIT_STRING_PREFERENCE(macro) \100 FOR_EACH_WEBKIT_STRING_PREFERENCE_NOT_IN_WEBCORE(macro) \101 \102 -
trunk/Source/WebKit/Shared/WebPreferences.yaml
r224043 r224077 3 3 type: bool 4 4 defaultValue: true 5 webcoreName: scriptEnabled 5 6 6 7 JavaScriptMarkupEnabled: 7 8 type: bool 8 9 defaultValue: true 10 webcoreName: scriptMarkupEnabled 9 11 10 12 LoadsImagesAutomatically: … … 15 17 type: bool 16 18 defaultValue: false 19 webcoreName: loadsSiteIconsIgnoringImageLoadingSetting 17 20 18 21 PluginsEnabled: … … 39 42 type: bool 40 43 defaultValue: true 44 webcoreBinding: custom 41 45 42 46 XSSAuditorEnabled: … … 47 51 type: bool 48 52 defaultValue: false 53 webcoreBinding: none 49 54 50 55 TextAreasAreResizable: … … 71 76 type: bool 72 77 defaultValue: false 78 webcoreBinding: none 73 79 74 80 CanvasUsesAcceleratedDrawing: … … 91 97 type: bool 92 98 defaultValue: true 99 webcoreBinding: RuntimeEnabledFeatures 100 webcoreName: animationTriggersEnabled 101 condition: ENABLE(CSS_ANIMATIONS_LEVEL_2) 93 102 94 103 ForceFTPDirectoryListings: … … 99 108 type: bool 100 109 defaultValue: DEFAULT_WEBKIT_TABSTOLINKS_ENABLED 110 webcoreBinding: none 101 111 102 112 DNSPrefetchingEnabled: … … 111 121 type: bool 112 122 defaultValue: false 123 condition: ENABLE(WEB_ARCHIVE) 113 124 114 125 LocalFileContentSniffingEnabled: … … 147 158 type: bool 148 159 defaultValue: DEFAULT_LINK_PRECONNECT_ENABLED 160 webcoreName: linkPreconnectEnabled 149 161 150 162 FullScreenEnabled: 151 163 type: bool 152 164 defaultValue: false 165 condition: ENABLE(FULLSCREEN_API) 153 166 154 167 AsynchronousSpellCheckingEnabled: … … 172 185 defaultValue: true 173 186 getter: isAVFoundationEnabled 187 webcoreBinding: DeprecatedGlobalSettings 188 condition: USE(AVFOUNDATION) 174 189 175 190 AVFoundationNSURLSessionEnabled: … … 177 192 defaultValue: true 178 193 getter: isAVFoundationNSURLSessionEnabled 194 webcoreBinding: DeprecatedGlobalSettings 195 condition: USE(AVFOUNDATION) 179 196 180 197 GStreamerEnabled: … … 182 199 defaultValue: true 183 200 getter: isGStreamerEnabled 201 webcoreBinding: DeprecatedGlobalSettings 202 condition: USE(GSTREAMER) 184 203 185 204 RequiresUserGestureForMediaPlayback: 186 205 type: bool 187 206 defaultValue: false 207 webcoreBinding: custom 188 208 189 209 RequiresUserGestureForVideoPlayback: 190 210 type: bool 191 211 defaultValue: false 212 webcoreBinding: custom 192 213 193 214 RequiresUserGestureForAudioPlayback: 194 215 type: bool 195 216 defaultValue: DEFAULT_REQUIRES_USER_GESTURE_FOR_AUDIO_PLAYBACK 217 webcoreBinding: custom 196 218 197 219 RequiresUserGestureToLoadVideo: … … 234 256 type: bool 235 257 defaultValue: true 258 condition: ENABLE(WIRELESS_PLAYBACK_TARGET) 236 259 237 260 MediaControlsScaleWithPageZoom: … … 242 265 type: bool 243 266 defaultValue: true 267 webcoreBinding: none 244 268 245 269 ShowsToolTipOverTruncatedText: … … 250 274 type: bool 251 275 defaultValue: false 276 webcoreBinding: DeprecatedGlobalSettings 252 277 253 278 WebAudioEnabled: 254 279 type: bool 255 280 defaultValue: true 281 condition: ENABLE(WEB_AUDIO) 256 282 257 283 AttachmentElementEnabled: 258 284 type: bool 259 285 defaultValue: false 286 webcoreBinding: RuntimeEnabledFeatures 287 condition: ENABLE(ATTACHMENT_ELEMENT) 260 288 261 289 SuppressesIncrementalRendering: … … 274 302 type: bool 275 303 defaultValue: false 304 condition: ENABLE(VIDEO_TRACK) 276 305 277 306 ShouldDisplayCaptions: 278 307 type: bool 279 308 defaultValue: false 309 condition: ENABLE(VIDEO_TRACK) 280 310 281 311 ShouldDisplayTextDescriptions: 282 312 type: bool 283 313 defaultValue: false 314 condition: ENABLE(VIDEO_TRACK) 284 315 285 316 NotificationsEnabled: 286 317 type: bool 287 318 defaultValue: true 319 condition: ENABLE(NOTIFICATIONS) 288 320 289 321 ShouldRespectImageOrientation: … … 306 338 type: bool 307 339 defaultValue: false 340 webcoreBinding: none 308 341 309 342 AsynchronousPluginInitializationEnabledForAllPlugins: 310 343 type: bool 311 344 defaultValue: false 345 webcoreBinding: none 312 346 313 347 ArtificialPluginInitializationDelayEnabled: 314 348 type: bool 315 349 defaultValue: false 316 350 webcoreBinding: none 351 352 # FIXME: What is this? 317 353 TabToLinksEnabled: 318 354 type: bool 319 355 defaultValue: false 356 webcoreBinding: none 320 357 321 358 ScrollingPerformanceLoggingEnabled: 322 359 type: bool 323 360 defaultValue: false 361 webcoreBinding: custom 324 362 325 363 ScrollAnimatorEnabled: 326 364 type: bool 327 365 defaultValue: DEFAULT_WEBKIT_SCROLL_ANIMATOR_ENABLED 366 condition: ENABLE(SMOOTH_SCROLLING) 328 367 329 368 ForceUpdateScrollbarsOnMainThreadForPerformanceTesting: … … 354 393 type: bool 355 394 defaultValue: DEFAULT_PDFPLUGIN_ENABLED 395 webcoreBinding: none 396 condition: PLATFORM(COCOA) 356 397 357 398 UsesEncodingDetector: … … 362 403 type: bool 363 404 defaultValue: WebCore::Settings::defaultTextAutosizingEnabled() 405 condition: ENABLE(TEXT_AUTOSIZING) 364 406 365 407 AggressiveTileRetentionEnabled: … … 375 417 defaultValue: WebCore::DeprecatedGlobalSettings::isQTKitEnabled() 376 418 getter: isQTKitEnabled 419 webcoreBinding: DeprecatedGlobalSettings 420 condition: PLATFORM(COCOA) 377 421 378 422 PageVisibilityBasedProcessSuppressionEnabled: 379 423 type: bool 380 424 defaultValue: true 425 webcoreBinding: none 381 426 382 427 SmartInsertDeleteEnabled: … … 391 436 type: bool 392 437 defaultValue: false 438 webcoreName: showsURLsInToolTips 393 439 394 440 AcceleratedCompositingForOverflowScrollEnabled: … … 411 457 type: bool 412 458 defaultValue: false 459 webcoreBinding: DeprecatedGlobalSettings 413 460 414 461 ThreadedScrollingEnabled: 415 462 type: bool 416 463 defaultValue: true 464 webcoreBinding: none 417 465 418 466 SimpleLineLayoutEnabled: … … 431 479 type: bool 432 480 defaultValue: false 481 webcoreBinding: RuntimeEnabledFeatures 482 condition: ENABLE(MEDIA_STREAM) 433 483 434 484 MediaStreamEnabled: 435 485 type: bool 436 486 defaultValue: true 487 webcoreBinding: RuntimeEnabledFeatures 488 condition: ENABLE(MEDIA_STREAM) 437 489 438 490 PeerConnectionEnabled: 439 491 type: bool 440 492 defaultValue: WebCore::LibWebRTCProvider::webRTCAvailable() 493 webcoreBinding: RuntimeEnabledFeatures 494 condition: ENABLE(WEB_RTC) 441 495 442 496 UseLegacyTextAlignPositionedElementBehavior: … … 451 505 type: bool 452 506 defaultValue: true 507 condition: ENABLE(MEDIA_SOURCE) 453 508 454 509 ViewGestureDebuggingEnabled: 455 510 type: bool 456 511 defaultValue: false 512 webcoreBinding: none 457 513 458 514 ShouldConvertPositionStyleOnCopy: … … 483 539 type: bool 484 540 defaultValue: false 541 condition: ENABLE(SERVICE_CONTROLS) 485 542 486 543 EnableInheritURIQueryComponent: … … 491 548 type: bool 492 549 defaultValue: false 550 condition: ENABLE(SERVICE_CONTROLS) 493 551 494 552 DeferredCSSParserEnabled: … … 499 557 type: bool 500 558 defaultValue: true 559 webcoreName: httpEquivEnabled 501 560 502 561 MockCaptureDevicesEnabled: 503 562 type: bool 504 563 defaultValue: false 564 webcoreBinding: DeprecatedGlobalSettings 565 condition: ENABLE(MEDIA_STREAM) 505 566 506 567 MockCaptureDevicesPromptEnabled: 507 568 type: bool 508 569 defaultValue: true 570 webcoreBinding: none 509 571 510 572 MediaCaptureRequiresSecureConnection: 511 573 type: bool 512 574 defaultValue: true 513 575 webcoreBinding: DeprecatedGlobalSettings 576 condition: ENABLE(MEDIA_STREAM) 577 578 # FIXME: What is this for? 514 579 EnumeratingAllNetworkInterfacesEnabled: 515 580 type: bool 516 581 defaultValue: false 517 582 webcoreBinding: none 583 584 # FIXME: What is this for? 518 585 ICECandidateFilteringEnabled: 519 586 type: bool 520 587 defaultValue: true 588 webcoreBinding: none 521 589 522 590 ShadowDOMEnabled: … … 525 593 humanReadableName: "Shadow DOM" 526 594 humanReadableDescription: "HTML Shadow DOM prototype" 595 webcoreBinding: RuntimeEnabledFeatures 527 596 528 597 FetchAPIEnabled: 529 598 type: bool 530 599 defaultValue: true 600 webcoreBinding: RuntimeEnabledFeatures 531 601 532 602 DownloadAttributeEnabled: 533 603 type: bool 534 604 defaultValue: true 605 webcoreBinding: RuntimeEnabledFeatures 606 condition: ENABLE(DOWNLOAD_ATTRIBUTE) 535 607 536 608 SelectionPaintingWithoutSelectionGapsEnabled: … … 541 613 type: bool 542 614 defaultValue: false 615 condition: ENABLE(APPLE_PAY) 543 616 544 617 ApplePayCapabilityDisclosureAllowed: 545 618 type: bool 546 619 defaultValue: true 620 condition: ENABLE(APPLE_PAY) 547 621 548 622 VisualViewportEnabled: … … 565 639 type: bool 566 640 defaultValue: true 641 webcoreBinding: RuntimeEnabledFeatures 567 642 568 643 EncryptedMediaAPIEnabled: 569 644 type: bool 570 645 defaultValue: false 646 webcoreBinding: RuntimeEnabledFeatures 647 condition: ENABLE(ENCRYPTED_MEDIA) 571 648 572 649 MediaPreloadingEnabled: 573 650 type: bool 574 651 defaultValue: false 652 webcoreBinding: RuntimeEnabledFeatures 575 653 576 654 IntersectionObserverEnabled: … … 579 657 humanReadableName: "Intersection Observer" 580 658 humanReadableDescription: "Enable Intersection Observer support" 659 webcoreBinding: RuntimeEnabledFeatures 660 condition: ENABLE(INTERSECTION_OBSERVER) 581 661 582 662 InteractiveFormValidationEnabled: … … 585 665 humanReadableName: "HTML Interactive Form Validation" 586 666 humanReadableDescription: "HTML interactive form validation" 667 webcoreBinding: RuntimeEnabledFeatures 587 668 588 669 ShouldSuppressTextInputFromEditingDuringProvisionalNavigation: … … 595 676 humanReadableName: "CSS Grid" 596 677 humanReadableDescription: "CSS Grid Layout Module support" 678 binding: RuntimeEnabledFeatures 679 webcoreBinding: RuntimeEnabledFeatures 597 680 598 681 GamepadsEnabled: … … 601 684 humanReadableName: "Gamepads" 602 685 humanReadableDescription: "Web Gamepad API support" 686 webcoreBinding: RuntimeEnabledFeatures 687 condition: ENABLE(GAMEPAD) 603 688 604 689 InputEventsEnabled: … … 607 692 humanReadableName: "Input Events" 608 693 humanReadableDescription: "Enable InputEvents support" 694 webcoreBinding: RuntimeEnabledFeatures 609 695 610 696 CredentialManagementEnabled: … … 613 699 humanReadableName: "Credential Management" 614 700 humanReadableDescription: "Enable Credential Management support" 701 webcoreBinding: RuntimeEnabledFeatures 615 702 616 703 ModernMediaControlsEnabled: … … 619 706 humanReadableName: "Modern Media Controls" 620 707 humanReadableDescription: "Use modern media controls look" 708 webcoreBinding: RuntimeEnabledFeatures 621 709 622 710 ResourceTimingEnabled: … … 625 713 humanReadableName: "Resource Timing" 626 714 humanReadableDescription: "Enable ResourceTiming API" 715 webcoreBinding: RuntimeEnabledFeatures 627 716 628 717 UserTimingEnabled: … … 631 720 humanReadableName: "User Timing" 632 721 humanReadableDescription: "Enable UserTiming API" 722 webcoreBinding: RuntimeEnabledFeatures 633 723 634 724 BeaconAPIEnabled: … … 637 727 humanReadableName: "Beacon API" 638 728 humanReadableDescription: "Beacon API" 729 condition: ENABLE(BEACON_API) 639 730 640 731 LegacyEncryptedMediaAPIEnabled: … … 643 734 humanReadableName: "Enable Legacy EME API" 644 735 humanReadableDescription: "Enable legacy EME API" 736 webcoreBinding: RuntimeEnabledFeatures 737 condition: ENABLE(LEGACY_ENCRYPTED_MEDIA) 645 738 646 739 AllowMediaContentTypesRequiringHardwareSupportAsFallback: … … 655 748 humanReadableName: "Web Inspector Additions" 656 749 humanReadableDescription: "Enable additional page APIs used by the Web Inspector frontend page" 750 webcoreBinding: RuntimeEnabledFeatures 657 751 658 752 DirectoryUploadEnabled: … … 661 755 humanReadableName: "Directory Upload" 662 756 humanReadableDescription: "input.webkitdirectory / dataTransferItem.webkitGetAsEntry()" 757 webcoreBinding: RuntimeEnabledFeatures 663 758 664 759 DataTransferItemsEnabled: … … 667 762 humanReadableName: "Data Transfer Items" 668 763 humanReadableDescription: "Enables DataTransferItem in the clipboard API" 764 webcoreBinding: RuntimeEnabledFeatures 669 765 670 766 CustomPasteboardDataEnabled: … … 673 769 humanReadableName: "Custom pateboard data" 674 770 humanReadableDescription: "Enable custom clipboard types and better security model for clipboard API." 771 webcoreBinding: DeprecatedGlobalSettings 675 772 676 773 WebVREnabled: … … 679 776 humanReadableName: "WebVR" 680 777 humanReadableDescription: "WebVR Module support" 778 webcoreBinding: RuntimeEnabledFeatures 681 779 682 780 ViewportFitEnabled: … … 689 787 type: double 690 788 defaultValue: 5 789 webcoreName: incrementalRenderingSuppressionTimeoutInSeconds 691 790 692 791 MinimumFontSize: … … 701 800 type: double 702 801 defaultValue: WebCore::Settings::defaultMinimumZoomFontSize() 802 condition: ENABLE(TEXT_AUTOSIZING) 703 803 704 804 DefaultFontSize: … … 713 813 type: double 714 814 defaultValue: -1 815 webcoreBinding: custom 715 816 716 817 MaxParseDuration: … … 721 822 type: double 722 823 defaultValue: 2 723 824 webcoreName: passwordEchoDurationInSeconds 825 826 # FIXME: 724 827 FontSmoothingLevel: 725 828 type: uint32_t 726 829 defaultValue: FontSmoothingLevelMedium 830 webcoreBinding: none 727 831 728 832 LayoutFallbackWidth: … … 741 845 type: uint32_t 742 846 defaultValue: WebCore::EditableLinkNeverLive 847 webcoreBinding: custom 743 848 744 849 InspectorAttachedHeight: 745 850 type: uint32_t 746 851 defaultValue: 300 852 webcoreBinding: none 747 853 748 854 InspectorAttachedWidth: 749 855 type: uint32_t 750 856 defaultValue: 750 857 webcoreBinding: none 751 858 752 859 InspectorAttachmentSide: 753 860 type: uint32_t 754 861 defaultValue: 0 862 webcoreBinding: none 755 863 756 864 StorageBlockingPolicy: 757 865 type: uint32_t 758 866 defaultValue: WebCore::SecurityOrigin::BlockThirdPartyStorage 867 webcoreBinding: custom 759 868 760 869 JavaScriptRuntimeFlags: 761 870 type: uint32_t 762 871 defaultValue: 0 872 webcoreBinding: custom 763 873 764 874 DataDetectorTypes: 765 875 type: uint32_t 766 876 defaultValue: 0 877 webcoreBinding: custom 878 condition: ENABLE(DATA_DETECTION) 767 879 768 880 UserInterfaceDirectionPolicy: 769 881 type: uint32_t 770 882 defaultValue: 0 883 webcoreBinding: custom 771 884 772 885 SystemLayoutDirection: 773 886 type: uint32_t 774 887 defaultValue: 0 888 webcoreBinding: custom 775 889 776 890 FrameFlattening: 777 891 type: uint32_t 778 892 defaultValue: DEFAULT_FRAME_FLATTENING 893 webcoreBinding: custom 779 894 780 895 StandardFontFamily: … … 821 936 type: String 822 937 defaultValue: '""' 823 web kitOnly: true938 webcoreBinding: none 824 939 825 940 InactiveMediaCaptureSteamRepromptIntervalInMinutes: 826 type: double 827 defaultValue: DEFAULT_INTERACTIVE_MNEDIA_CAPTURE_STREAM_REPROMPT_INTERVAL_IN_MINUTES 941 type: double 942 defaultValue: DEFAULT_INTERACTIVE_MNEDIA_CAPTURE_STREAM_REPROMPT_INTERVAL_IN_MINUTES 943 webcoreBinding: none 828 944 829 945 LongRunningMediaCaptureStreamRepromptIntervalInHours: 830 type: double 831 defaultValue: 24 946 type: double 947 defaultValue: 24 948 webcoreBinding: none 949 832 950 833 951 # Debug Preferences 834 952 835 836 953 AcceleratedDrawingEnabled: 837 954 type: bool … … 853 970 defaultValue: false 854 971 category: debug 972 webcoreName: showDebugBorders 855 973 856 974 CompositingRepaintCountersVisible: … … 858 976 defaultValue: false 859 977 category: debug 978 webcoreName: showRepaintCounter 860 979 861 980 TiledScrollingIndicatorVisible: … … 863 982 defaultValue: false 864 983 category: debug 984 webcoreName: showTiledScrollingIndicator 865 985 866 986 SimpleLineLayoutDebugBordersEnabled: … … 883 1003 defaultValue: true 884 1004 category: debug 1005 webcoreBinding: none 1006 condition: PLATFORM(IOS) 885 1007 886 1008 ForceAlwaysUserScalable: … … 888 1010 defaultValue: false 889 1011 category: debug 1012 webcoreBinding: none 1013 condition: PLATFORM(IOS) 890 1014 891 1015 ResourceUsageOverlayVisible: … … 893 1017 defaultValue: false 894 1018 category: debug 1019 condition: ENABLE(RESOURCE_USAGE) 895 1020 896 1021 VisibleDebugOverlayRegions: … … 922 1047 humanReadableDescription: "Enable Cache API" 923 1048 category: experimental 1049 webcoreBinding: RuntimeEnabledFeatures 924 1050 925 1051 ConstantPropertiesEnabled: … … 936 1062 humanReadableDescription: "Enable CSS display: contents support" 937 1063 category: experimental 1064 webcoreBinding: RuntimeEnabledFeatures 938 1065 939 1066 SpringTimingFunctionEnabled: … … 950 1077 humanReadableDescription: "Link preload support" 951 1078 category: experimental 1079 webcoreBinding: RuntimeEnabledFeatures 952 1080 953 1081 WebRTCLegacyAPIDisabled: … … 957 1085 humanReadableDescription: "Remove Legacy WebRTC API" 958 1086 category: experimental 1087 webcoreBinding: custom 1088 condition: ENABLE(WEB_RTC) 959 1089 960 1090 IsSecureContextAttributeEnabled: … … 964 1094 humanReadableDescription: "Enable Secure Contexts API" 965 1095 category: experimental 1096 webcoreBinding: RuntimeEnabledFeatures 966 1097 967 1098 ServiceWorkersEnabled: … … 971 1102 humanReadableDescription: "Enable ServiceWorkers" 972 1103 category: experimental 1104 webcoreBinding: RuntimeEnabledFeatures 1105 webcoreName: serviceWorkerEnabled 1106 condition: ENABLE(SERVICE_WORKER) 973 1107 974 1108 StorageAccessAPIEnabled: … … 992 1126 humanReadableDescription: "Web Animations prototype" 993 1127 category: experimental 1128 webcoreBinding: RuntimeEnabledFeatures 994 1129 995 1130 WebGL2Enabled: … … 999 1134 humanReadableDescription: "WebGL 2 prototype" 1000 1135 category: experimental 1136 webcoreBinding: RuntimeEnabledFeatures 1137 condition: ENABLE(WEBGL2) 1001 1138 1002 1139 WebGPUEnabled: … … 1006 1143 humanReadableDescription: "WebGPU prototype" 1007 1144 category: experimental 1145 webcoreBinding: RuntimeEnabledFeatures 1146 condition: ENABLE(WEBGPU) -
trunk/Source/WebKit/WebKit.xcodeproj/project.pbxproj
r224041 r224077 1354 1354 7CE4D2271A4916C200C7F152 /* WebProcessPoolMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CE4D2251A4916C200C7F152 /* WebProcessPoolMessageReceiver.cpp */; }; 1355 1355 7CE4D2281A4916C200C7F152 /* WebProcessPoolMessages.h in Headers */ = {isa = PBXBuildFile; fileRef = 7CE4D2261A4916C200C7F152 /* WebProcessPoolMessages.h */; }; 1356 7CE9CE101FA0767A000177DE /* WebPageUpdatePreferences.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CE9CE0F1FA0764D000177DE /* WebPageUpdatePreferences.cpp */; }; 1356 1357 7CEFA9621AC0999300B910FD /* APIContentRuleListStoreCocoa.mm in Sources */ = {isa = PBXBuildFile; fileRef = 7CEFA9601AC0999300B910FD /* APIContentRuleListStoreCocoa.mm */; }; 1357 1358 7CF47FF617275B71008ACB91 /* WKBundlePageBanner.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 7CF47FF417275B71008ACB91 /* WKBundlePageBanner.cpp */; }; … … 3740 3741 7CE4D2251A4916C200C7F152 /* WebProcessPoolMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebProcessPoolMessageReceiver.cpp; sourceTree = "<group>"; }; 3741 3742 7CE4D2261A4916C200C7F152 /* WebProcessPoolMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebProcessPoolMessages.h; sourceTree = "<group>"; }; 3743 7CE9CE0F1FA0764D000177DE /* WebPageUpdatePreferences.cpp */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.cpp.cpp; path = WebPageUpdatePreferences.cpp; sourceTree = "<group>"; }; 3742 3744 7CEFA9601AC0999300B910FD /* APIContentRuleListStoreCocoa.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = APIContentRuleListStoreCocoa.mm; sourceTree = "<group>"; }; 3743 3745 7CF47FF417275B71008ACB91 /* WKBundlePageBanner.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WKBundlePageBanner.cpp; sourceTree = "<group>"; }; … … 8136 8138 BCBD3912125BB1A800D2C29F /* WebPageProxyMessageReceiver.cpp */, 8137 8139 BCBD3913125BB1A800D2C29F /* WebPageProxyMessages.h */, 8140 7CE9CE0F1FA0764D000177DE /* WebPageUpdatePreferences.cpp */, 8138 8141 7C4694C71A4B4EA000AD5845 /* WebPasteboardProxyMessageReceiver.cpp */, 8139 8142 7C4694C81A4B4EA100AD5845 /* WebPasteboardProxyMessages.h */, … … 10663 10666 BC857E8712B71EBB00EDEB2E /* WebPageProxyMac.mm in Sources */, 10664 10667 BCBD3914125BB1A800D2C29F /* WebPageProxyMessageReceiver.cpp in Sources */, 10668 7CE9CE101FA0767A000177DE /* WebPageUpdatePreferences.cpp in Sources */, 10665 10669 512127C31908239A00DAF35C /* WebPasteboardOverrides.cpp in Sources */, 10666 10670 7C4694D01A51E36800AD5845 /* WebPasteboardProxy.cpp in Sources */, -
trunk/Source/WebKit/WebProcess/WebPage/WebPage.cpp
r224043 r224077 3035 3035 void WebPage::updatePreferences(const WebPreferencesStore& store) 3036 3036 { 3037 updatePreferencesGenerated(store); 3038 3037 3039 Settings& settings = m_page->settings(); 3040 3041 bool requiresUserGestureForMedia = store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureForMediaPlaybackKey()); 3042 settings.setVideoPlaybackRequiresUserGesture(requiresUserGestureForMedia || store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureForVideoPlaybackKey())); 3043 settings.setAudioPlaybackRequiresUserGesture(requiresUserGestureForMedia || store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureForAudioPlaybackKey())); 3044 settings.setLayoutInterval(Seconds(store.getDoubleValueForKey(WebPreferencesKey::layoutIntervalKey()))); 3045 settings.setUserInterfaceDirectionPolicy(static_cast<WebCore::UserInterfaceDirectionPolicy>(store.getUInt32ValueForKey(WebPreferencesKey::userInterfaceDirectionPolicyKey()))); 3046 settings.setSystemLayoutDirection(static_cast<TextDirection>(store.getUInt32ValueForKey(WebPreferencesKey::systemLayoutDirectionKey()))); 3047 settings.setJavaScriptRuntimeFlags(static_cast<RuntimeFlags>(store.getUInt32ValueForKey(WebPreferencesKey::javaScriptRuntimeFlagsKey()))); 3048 settings.setStorageBlockingPolicy(static_cast<SecurityOrigin::StorageBlockingPolicy>(store.getUInt32ValueForKey(WebPreferencesKey::storageBlockingPolicyKey()))); 3049 settings.setFrameFlattening(static_cast<WebCore::FrameFlattening>(store.getUInt32ValueForKey(WebPreferencesKey::frameFlatteningKey()))); 3050 settings.setEditableLinkBehavior(static_cast<WebCore::EditableLinkBehavior>(store.getUInt32ValueForKey(WebPreferencesKey::editableLinkBehaviorKey()))); 3051 #if ENABLE(DATA_DETECTION) 3052 settings.setDataDetectorTypes(static_cast<DataDetectorTypes>(store.getUInt32ValueForKey(WebPreferencesKey::dataDetectorTypesKey()))); 3053 #endif 3054 3055 #if ENABLE(WEB_RTC) 3056 RuntimeEnabledFeatures::sharedFeatures().setWebRTCLegacyAPIEnabled(!store.getBoolValueForKey(WebPreferencesKey::webRTCLegacyAPIDisabledKey())); 3057 #endif 3058 3059 DatabaseManager::singleton().setIsAvailable(store.getBoolValueForKey(WebPreferencesKey::databasesEnabledKey())); 3038 3060 3039 3061 m_tabToLinks = store.getBoolValueForKey(WebPreferencesKey::tabsToLinksKey()); … … 3043 3065 3044 3066 m_scrollingPerformanceLoggingEnabled = store.getBoolValueForKey(WebPreferencesKey::scrollingPerformanceLoggingEnabledKey()); 3045 3046 #if PLATFORM(COCOA) 3047 m_pdfPluginEnabled = store.getBoolValueForKey(WebPreferencesKey::pdfPluginEnabledKey()); 3048 #endif 3049 3050 // FIXME: This should be generated from macro expansion for all preferences, 3051 // but we currently don't match the naming of WebCore exactly so we are 3052 // handrolling the boolean and integer preferences until that is fixed. 3053 3054 #define INITIALIZE_SETTINGS(KeyUpper, KeyLower, TypeName, Type, DefaultValue, HumanReadableName, HumanReadableDescription) settings.set##KeyUpper(store.get##TypeName##ValueForKey(WebPreferencesKey::KeyLower##Key())); 3055 3056 FOR_EACH_WEBKIT_STRING_PREFERENCE(INITIALIZE_SETTINGS) 3057 3058 #undef INITIALIZE_SETTINGS 3059 3060 settings.setScriptEnabled(store.getBoolValueForKey(WebPreferencesKey::javaScriptEnabledKey())); 3061 settings.setScriptMarkupEnabled(store.getBoolValueForKey(WebPreferencesKey::javaScriptMarkupEnabledKey())); 3062 settings.setLoadsImagesAutomatically(store.getBoolValueForKey(WebPreferencesKey::loadsImagesAutomaticallyKey())); 3063 settings.setLoadsSiteIconsIgnoringImageLoadingSetting(store.getBoolValueForKey(WebPreferencesKey::loadsSiteIconsIgnoringImageLoadingPreferenceKey())); 3064 settings.setPluginsEnabled(store.getBoolValueForKey(WebPreferencesKey::pluginsEnabledKey())); 3065 settings.setJavaEnabled(store.getBoolValueForKey(WebPreferencesKey::javaEnabledKey())); 3066 settings.setJavaEnabledForLocalFiles(store.getBoolValueForKey(WebPreferencesKey::javaEnabledForLocalFilesKey())); 3067 settings.setOfflineWebApplicationCacheEnabled(store.getBoolValueForKey(WebPreferencesKey::offlineWebApplicationCacheEnabledKey())); 3068 settings.setLocalStorageEnabled(store.getBoolValueForKey(WebPreferencesKey::localStorageEnabledKey())); 3069 settings.setXSSAuditorEnabled(store.getBoolValueForKey(WebPreferencesKey::xssAuditorEnabledKey())); 3070 settings.setFrameFlattening(static_cast<WebCore::FrameFlattening>(store.getUInt32ValueForKey(WebPreferencesKey::frameFlatteningKey()))); 3071 settings.setAsyncFrameScrollingEnabled(store.getBoolValueForKey(WebPreferencesKey::asyncFrameScrollingEnabledKey())); 3067 settings.setScrollingPerformanceLoggingEnabled(m_scrollingPerformanceLoggingEnabled); 3068 3072 3069 if (store.getBoolValueForKey(WebPreferencesKey::privateBrowsingEnabledKey()) && !usesEphemeralSession()) 3073 3070 setSessionID(PAL::SessionID::legacyPrivateSessionID()); 3074 3071 else if (!store.getBoolValueForKey(WebPreferencesKey::privateBrowsingEnabledKey()) && sessionID() == PAL::SessionID::legacyPrivateSessionID()) 3075 3072 setSessionID(PAL::SessionID::defaultSessionID()); 3076 settings.setDeveloperExtrasEnabled(store.getBoolValueForKey(WebPreferencesKey::developerExtrasEnabledKey()));3077 settings.setJavaScriptRuntimeFlags(RuntimeFlags(store.getUInt32ValueForKey(WebPreferencesKey::javaScriptRuntimeFlagsKey())));3078 settings.setTextAreasAreResizable(store.getBoolValueForKey(WebPreferencesKey::textAreasAreResizableKey()));3079 settings.setNeedsSiteSpecificQuirks(store.getBoolValueForKey(WebPreferencesKey::needsSiteSpecificQuirksKey()));3080 settings.setJavaScriptCanOpenWindowsAutomatically(store.getBoolValueForKey(WebPreferencesKey::javaScriptCanOpenWindowsAutomaticallyKey()));3081 settings.setForceFTPDirectoryListings(store.getBoolValueForKey(WebPreferencesKey::forceFTPDirectoryListingsKey()));3082 settings.setDNSPrefetchingEnabled(store.getBoolValueForKey(WebPreferencesKey::dnsPrefetchingEnabledKey()));3083 settings.setDOMTimersThrottlingEnabled(store.getBoolValueForKey(WebPreferencesKey::domTimersThrottlingEnabledKey()));3084 #if ENABLE(WEB_ARCHIVE)3085 settings.setWebArchiveDebugModeEnabled(store.getBoolValueForKey(WebPreferencesKey::webArchiveDebugModeEnabledKey()));3086 #endif3087 settings.setLocalFileContentSniffingEnabled(store.getBoolValueForKey(WebPreferencesKey::localFileContentSniffingEnabledKey()));3088 settings.setUsesPageCache(store.getBoolValueForKey(WebPreferencesKey::usesPageCacheKey()));3089 settings.setPageCacheSupportsPlugins(store.getBoolValueForKey(WebPreferencesKey::pageCacheSupportsPluginsKey()));3090 settings.setAuthorAndUserStylesEnabled(store.getBoolValueForKey(WebPreferencesKey::authorAndUserStylesEnabledKey()));3091 settings.setPaginateDuringLayoutEnabled(store.getBoolValueForKey(WebPreferencesKey::paginateDuringLayoutEnabledKey()));3092 settings.setDOMPasteAllowed(store.getBoolValueForKey(WebPreferencesKey::domPasteAllowedKey()));3093 settings.setJavaScriptCanAccessClipboard(store.getBoolValueForKey(WebPreferencesKey::javaScriptCanAccessClipboardKey()));3094 settings.setLinkPreconnectEnabled(store.getBoolValueForKey(WebPreferencesKey::linkPreconnectKey()));3095 settings.setShouldPrintBackgrounds(store.getBoolValueForKey(WebPreferencesKey::shouldPrintBackgroundsKey()));3096 settings.setWebSecurityEnabled(store.getBoolValueForKey(WebPreferencesKey::webSecurityEnabledKey()));3097 settings.setAllowUniversalAccessFromFileURLs(store.getBoolValueForKey(WebPreferencesKey::allowUniversalAccessFromFileURLsKey()));3098 settings.setAllowFileAccessFromFileURLs(store.getBoolValueForKey(WebPreferencesKey::allowFileAccessFromFileURLsKey()));3099 settings.setNeedsStorageAccessFromFileURLsQuirk(store.getBoolValueForKey(WebPreferencesKey::needsStorageAccessFromFileURLsQuirkKey()));3100 3101 settings.setMinimumFontSize(store.getDoubleValueForKey(WebPreferencesKey::minimumFontSizeKey()));3102 settings.setMinimumLogicalFontSize(store.getDoubleValueForKey(WebPreferencesKey::minimumLogicalFontSizeKey()));3103 settings.setDefaultFontSize(store.getDoubleValueForKey(WebPreferencesKey::defaultFontSizeKey()));3104 settings.setDefaultFixedFontSize(store.getDoubleValueForKey(WebPreferencesKey::defaultFixedFontSizeKey()));3105 settings.setLayoutFallbackWidth(store.getUInt32ValueForKey(WebPreferencesKey::layoutFallbackWidthKey()));3106 settings.setDeviceWidth(store.getUInt32ValueForKey(WebPreferencesKey::deviceWidthKey()));3107 settings.setDeviceHeight(store.getUInt32ValueForKey(WebPreferencesKey::deviceHeightKey()));3108 settings.setEditableLinkBehavior(static_cast<WebCore::EditableLinkBehavior>(store.getUInt32ValueForKey(WebPreferencesKey::editableLinkBehaviorKey())));3109 settings.setShowsToolTipOverTruncatedText(store.getBoolValueForKey(WebPreferencesKey::showsToolTipOverTruncatedTextKey()));3110 3111 settings.setAcceleratedCompositingForOverflowScrollEnabled(store.getBoolValueForKey(WebPreferencesKey::acceleratedCompositingForOverflowScrollEnabledKey()));3112 settings.setAcceleratedCompositingEnabled(store.getBoolValueForKey(WebPreferencesKey::acceleratedCompositingEnabledKey()));3113 settings.setAcceleratedDrawingEnabled(store.getBoolValueForKey(WebPreferencesKey::acceleratedDrawingEnabledKey()));3114 settings.setDisplayListDrawingEnabled(store.getBoolValueForKey(WebPreferencesKey::displayListDrawingEnabledKey()));3115 settings.setCanvasUsesAcceleratedDrawing(store.getBoolValueForKey(WebPreferencesKey::canvasUsesAcceleratedDrawingKey()));3116 settings.setShowDebugBorders(store.getBoolValueForKey(WebPreferencesKey::compositingBordersVisibleKey()));3117 settings.setShowRepaintCounter(store.getBoolValueForKey(WebPreferencesKey::compositingRepaintCountersVisibleKey()));3118 settings.setShowTiledScrollingIndicator(store.getBoolValueForKey(WebPreferencesKey::tiledScrollingIndicatorVisibleKey()));3119 settings.setVisibleDebugOverlayRegions(store.getUInt32ValueForKey(WebPreferencesKey::visibleDebugOverlayRegionsKey()));3120 settings.setUseGiantTiles(store.getBoolValueForKey(WebPreferencesKey::useGiantTilesKey()));3121 settings.setSubpixelAntialiasedLayerTextEnabled(store.getBoolValueForKey(WebPreferencesKey::subpixelAntialiasedLayerTextEnabledKey()));3122 3123 settings.setAggressiveTileRetentionEnabled(store.getBoolValueForKey(WebPreferencesKey::aggressiveTileRetentionEnabledKey()));3124 settings.setTemporaryTileCohortRetentionEnabled(store.getBoolValueForKey(WebPreferencesKey::temporaryTileCohortRetentionEnabledKey()));3125 #if ENABLE(CSS_ANIMATIONS_LEVEL_2)3126 RuntimeEnabledFeatures::sharedFeatures().setAnimationTriggersEnabled(store.getBoolValueForKey(WebPreferencesKey::cssAnimationTriggersEnabledKey()));3127 #endif3128 RuntimeEnabledFeatures::sharedFeatures().setWebAnimationsEnabled(store.getBoolValueForKey(WebPreferencesKey::webAnimationsEnabledKey()));3129 settings.setWebGLEnabled(store.getBoolValueForKey(WebPreferencesKey::webGLEnabledKey()));3130 settings.setForceSoftwareWebGLRendering(store.getBoolValueForKey(WebPreferencesKey::forceSoftwareWebGLRenderingKey()));3131 settings.setAccelerated2dCanvasEnabled(store.getBoolValueForKey(WebPreferencesKey::accelerated2dCanvasEnabledKey()));3132 bool requiresUserGestureForMedia = store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureForMediaPlaybackKey());3133 settings.setVideoPlaybackRequiresUserGesture(requiresUserGestureForMedia || store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureForVideoPlaybackKey()));3134 settings.setAudioPlaybackRequiresUserGesture(requiresUserGestureForMedia || store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureForAudioPlaybackKey()));3135 settings.setRequiresUserGestureToLoadVideo(store.getBoolValueForKey(WebPreferencesKey::requiresUserGestureToLoadVideoKey()));3136 settings.setMainContentUserGestureOverrideEnabled(store.getBoolValueForKey(WebPreferencesKey::mainContentUserGestureOverrideEnabledKey()));3137 settings.setMediaUserGestureInheritsFromDocument(store.getBoolValueForKey(WebPreferencesKey::mediaUserGestureInheritsFromDocumentKey()));3138 settings.setAllowsInlineMediaPlayback(store.getBoolValueForKey(WebPreferencesKey::allowsInlineMediaPlaybackKey()));3139 settings.setAllowsInlineMediaPlaybackAfterFullscreen(store.getBoolValueForKey(WebPreferencesKey::allowsInlineMediaPlaybackAfterFullscreenKey()));3140 settings.setInlineMediaPlaybackRequiresPlaysInlineAttribute(store.getBoolValueForKey(WebPreferencesKey::inlineMediaPlaybackRequiresPlaysInlineAttributeKey()));3141 settings.setInvisibleAutoplayNotPermitted(store.getBoolValueForKey(WebPreferencesKey::invisibleAutoplayNotPermittedKey()));3142 settings.setMediaDataLoadsAutomatically(store.getBoolValueForKey(WebPreferencesKey::mediaDataLoadsAutomaticallyKey()));3143 settings.setAllowsPictureInPictureMediaPlayback(store.getBoolValueForKey(WebPreferencesKey::allowsPictureInPictureMediaPlaybackKey()));3144 settings.setMediaControlsScaleWithPageZoom(store.getBoolValueForKey(WebPreferencesKey::mediaControlsScaleWithPageZoomKey()));3145 DeprecatedGlobalSettings::setMockScrollbarsEnabled(store.getBoolValueForKey(WebPreferencesKey::mockScrollbarsEnabledKey()));3146 settings.setHyperlinkAuditingEnabled(store.getBoolValueForKey(WebPreferencesKey::hyperlinkAuditingEnabledKey()));3147 settings.setRequestAnimationFrameEnabled(store.getBoolValueForKey(WebPreferencesKey::requestAnimationFrameEnabledKey()));3148 #if ENABLE(SMOOTH_SCROLLING)3149 settings.setScrollAnimatorEnabled(store.getBoolValueForKey(WebPreferencesKey::scrollAnimatorEnabledKey()));3150 #endif3151 settings.setForceUpdateScrollbarsOnMainThreadForPerformanceTesting(store.getBoolValueForKey(WebPreferencesKey::forceUpdateScrollbarsOnMainThreadForPerformanceTestingKey()));3152 settings.setInteractiveFormValidationEnabled(store.getBoolValueForKey(WebPreferencesKey::interactiveFormValidationEnabledKey()));3153 settings.setSpatialNavigationEnabled(store.getBoolValueForKey(WebPreferencesKey::spatialNavigationEnabledKey()));3154 3155 settings.setHttpEquivEnabled(store.getBoolValueForKey(WebPreferencesKey::httpEquivEnabledKey()));3156 3157 settings.setSelectionPaintingWithoutSelectionGapsEnabled(store.getBoolValueForKey(WebPreferencesKey::selectionPaintingWithoutSelectionGapsEnabledKey()));3158 3159 DatabaseManager::singleton().setIsAvailable(store.getBoolValueForKey(WebPreferencesKey::databasesEnabledKey()));3160 3161 #if ENABLE(FULLSCREEN_API)3162 settings.setFullScreenEnabled(store.getBoolValueForKey(WebPreferencesKey::fullScreenEnabledKey()));3163 #endif3164 3165 #if USE(AVFOUNDATION)3166 DeprecatedGlobalSettings::setAVFoundationEnabled(store.getBoolValueForKey(WebPreferencesKey::isAVFoundationEnabledKey()));3167 DeprecatedGlobalSettings::setAVFoundationNSURLSessionEnabled(store.getBoolValueForKey(WebPreferencesKey::isAVFoundationNSURLSessionEnabledKey()));3168 #endif3169 3170 #if USE(GSTREAMER)3171 DeprecatedGlobalSettings::setGStreamerEnabled(store.getBoolValueForKey(WebPreferencesKey::isGStreamerEnabledKey()));3172 #endif3173 3174 #if PLATFORM(COCOA)3175 DeprecatedGlobalSettings::setQTKitEnabled(store.getBoolValueForKey(WebPreferencesKey::isQTKitEnabledKey()));3176 #endif3177 3178 #if PLATFORM(IOS) && HAVE(AVKIT)3179 DeprecatedGlobalSettings::setAVKitEnabled(true);3180 #endif3181 3182 #if ENABLE(WEB_AUDIO)3183 settings.setWebAudioEnabled(store.getBoolValueForKey(WebPreferencesKey::webAudioEnabledKey()));3184 #endif3185 3186 #if ENABLE(MEDIA_STREAM)3187 RuntimeEnabledFeatures::sharedFeatures().setMediaDevicesEnabled(store.getBoolValueForKey(WebPreferencesKey::mediaDevicesEnabledKey()));3188 RuntimeEnabledFeatures::sharedFeatures().setMediaStreamEnabled(store.getBoolValueForKey(WebPreferencesKey::mediaStreamEnabledKey()));3189 #endif3190 3191 #if ENABLE(WEB_RTC)3192 RuntimeEnabledFeatures::sharedFeatures().setPeerConnectionEnabled(store.getBoolValueForKey(WebPreferencesKey::peerConnectionEnabledKey()));3193 RuntimeEnabledFeatures::sharedFeatures().setWebRTCLegacyAPIEnabled(!store.getBoolValueForKey(WebPreferencesKey::webRTCLegacyAPIDisabledKey()));3194 #endif3195 3196 #if ENABLE(SERVICE_CONTROLS)3197 settings.setImageControlsEnabled(store.getBoolValueForKey(WebPreferencesKey::imageControlsEnabledKey()));3198 #endif3199 3200 #if ENABLE(SERVICE_WORKER)3201 RuntimeEnabledFeatures::sharedFeatures().setServiceWorkerEnabled(store.getBoolValueForKey(WebPreferencesKey::serviceWorkersEnabledKey()));3202 #endif3203 3204 #if ENABLE(WIRELESS_PLAYBACK_TARGET)3205 settings.setAllowsAirPlayForMediaPlayback(store.getBoolValueForKey(WebPreferencesKey::allowsAirPlayForMediaPlaybackKey()));3206 #endif3207 3208 #if ENABLE(RESOURCE_USAGE)3209 settings.setResourceUsageOverlayVisible(store.getBoolValueForKey(WebPreferencesKey::resourceUsageOverlayVisibleKey()));3210 #endif3211 3212 settings.setSuppressesIncrementalRendering(store.getBoolValueForKey(WebPreferencesKey::suppressesIncrementalRenderingKey()));3213 settings.setIncrementalRenderingSuppressionTimeoutInSeconds(store.getDoubleValueForKey(WebPreferencesKey::incrementalRenderingSuppressionTimeoutKey()));3214 settings.setBackspaceKeyNavigationEnabled(store.getBoolValueForKey(WebPreferencesKey::backspaceKeyNavigationEnabledKey()));3215 settings.setWantsBalancedSetDefersLoadingBehavior(store.getBoolValueForKey(WebPreferencesKey::wantsBalancedSetDefersLoadingBehaviorKey()));3216 settings.setCaretBrowsingEnabled(store.getBoolValueForKey(WebPreferencesKey::caretBrowsingEnabledKey()));3217 3218 #if ENABLE(VIDEO_TRACK)3219 settings.setShouldDisplaySubtitles(store.getBoolValueForKey(WebPreferencesKey::shouldDisplaySubtitlesKey()));3220 settings.setShouldDisplayCaptions(store.getBoolValueForKey(WebPreferencesKey::shouldDisplayCaptionsKey()));3221 settings.setShouldDisplayTextDescriptions(store.getBoolValueForKey(WebPreferencesKey::shouldDisplayTextDescriptionsKey()));3222 #endif3223 3224 #if ENABLE(NOTIFICATIONS)3225 settings.setNotificationsEnabled(store.getBoolValueForKey(WebPreferencesKey::notificationsEnabledKey()));3226 #endif3227 3228 settings.setShouldRespectImageOrientation(store.getBoolValueForKey(WebPreferencesKey::shouldRespectImageOrientationKey()));3229 settings.setStorageBlockingPolicy(static_cast<SecurityOrigin::StorageBlockingPolicy>(store.getUInt32ValueForKey(WebPreferencesKey::storageBlockingPolicyKey())));3230 settings.setCookieEnabled(store.getBoolValueForKey(WebPreferencesKey::cookieEnabledKey()));3231 3232 settings.setDiagnosticLoggingEnabled(store.getBoolValueForKey(WebPreferencesKey::diagnosticLoggingEnabledKey()));3233 3234 settings.setScrollingPerformanceLoggingEnabled(m_scrollingPerformanceLoggingEnabled);3235 3236 settings.setPlugInSnapshottingEnabled(store.getBoolValueForKey(WebPreferencesKey::plugInSnapshottingEnabledKey()));3237 settings.setSnapshotAllPlugIns(store.getBoolValueForKey(WebPreferencesKey::snapshotAllPlugInsKey()));3238 settings.setAutostartOriginPlugInSnapshottingEnabled(store.getBoolValueForKey(WebPreferencesKey::autostartOriginPlugInSnapshottingEnabledKey()));3239 settings.setPrimaryPlugInSnapshotDetectionEnabled(store.getBoolValueForKey(WebPreferencesKey::primaryPlugInSnapshotDetectionEnabledKey()));3240 settings.setUsesEncodingDetector(store.getBoolValueForKey(WebPreferencesKey::usesEncodingDetectorKey()));3241 3242 #if ENABLE(TEXT_AUTOSIZING)3243 settings.setTextAutosizingEnabled(store.getBoolValueForKey(WebPreferencesKey::textAutosizingEnabledKey()));3244 settings.setMinimumZoomFontSize(store.getDoubleValueForKey(WebPreferencesKey::minimumZoomFontSizeKey()));3245 #endif3246 3247 settings.setLogsPageMessagesToSystemConsoleEnabled(store.getBoolValueForKey(WebPreferencesKey::logsPageMessagesToSystemConsoleEnabledKey()));3248 settings.setAsynchronousSpellCheckingEnabled(store.getBoolValueForKey(WebPreferencesKey::asynchronousSpellCheckingEnabledKey()));3249 3250 settings.setSmartInsertDeleteEnabled(store.getBoolValueForKey(WebPreferencesKey::smartInsertDeleteEnabledKey()));3251 settings.setSelectTrailingWhitespaceEnabled(store.getBoolValueForKey(WebPreferencesKey::selectTrailingWhitespaceEnabledKey()));3252 settings.setShowsURLsInToolTips(store.getBoolValueForKey(WebPreferencesKey::showsURLsInToolTipsEnabledKey()));3253 3254 settings.setHiddenPageDOMTimerThrottlingEnabled(store.getBoolValueForKey(WebPreferencesKey::hiddenPageDOMTimerThrottlingEnabledKey()));3255 settings.setHiddenPageDOMTimerThrottlingAutoIncreases(store.getBoolValueForKey(WebPreferencesKey::hiddenPageDOMTimerThrottlingAutoIncreasesKey()));3256 3257 settings.setHiddenPageCSSAnimationSuspensionEnabled(store.getBoolValueForKey(WebPreferencesKey::hiddenPageCSSAnimationSuspensionEnabledKey()));3258 DeprecatedGlobalSettings::setLowPowerVideoAudioBufferSizeEnabled(store.getBoolValueForKey(WebPreferencesKey::lowPowerVideoAudioBufferSizeEnabledKey()));3259 settings.setSimpleLineLayoutEnabled(store.getBoolValueForKey(WebPreferencesKey::simpleLineLayoutEnabledKey()));3260 settings.setSimpleLineLayoutDebugBordersEnabled(store.getBoolValueForKey(WebPreferencesKey::simpleLineLayoutDebugBordersEnabledKey()));3261 3262 settings.setDeferredCSSParserEnabled(store.getBoolValueForKey(WebPreferencesKey::deferredCSSParserEnabledKey()));3263 3264 settings.setSubpixelCSSOMElementMetricsEnabled(store.getBoolValueForKey(WebPreferencesKey::subpixelCSSOMElementMetricsEnabledKey()));3265 3266 settings.setUseLegacyTextAlignPositionedElementBehavior(store.getBoolValueForKey(WebPreferencesKey::useLegacyTextAlignPositionedElementBehaviorKey()));3267 3268 #if ENABLE(MEDIA_SOURCE)3269 settings.setMediaSourceEnabled(store.getBoolValueForKey(WebPreferencesKey::mediaSourceEnabledKey()));3270 #endif3271 3272 #if ENABLE(MEDIA_STREAM)3273 DeprecatedGlobalSettings::setMockCaptureDevicesEnabled(store.getBoolValueForKey(WebPreferencesKey::mockCaptureDevicesEnabledKey()));3274 DeprecatedGlobalSettings::setMediaCaptureRequiresSecureConnection(store.getBoolValueForKey(WebPreferencesKey::mediaCaptureRequiresSecureConnectionKey()));3275 #endif3276 3277 settings.setShouldConvertPositionStyleOnCopy(store.getBoolValueForKey(WebPreferencesKey::shouldConvertPositionStyleOnCopyKey()));3278 3279 settings.setStandalone(store.getBoolValueForKey(WebPreferencesKey::standaloneKey()));3280 settings.setTelephoneNumberParsingEnabled(store.getBoolValueForKey(WebPreferencesKey::telephoneNumberParsingEnabledKey()));3281 settings.setAllowMultiElementImplicitSubmission(store.getBoolValueForKey(WebPreferencesKey::allowMultiElementImplicitSubmissionKey()));3282 settings.setAlwaysUseAcceleratedOverflowScroll(store.getBoolValueForKey(WebPreferencesKey::alwaysUseAcceleratedOverflowScrollKey()));3283 3284 settings.setPasswordEchoEnabled(store.getBoolValueForKey(WebPreferencesKey::passwordEchoEnabledKey()));3285 settings.setPasswordEchoDurationInSeconds(store.getDoubleValueForKey(WebPreferencesKey::passwordEchoDurationKey()));3286 3287 settings.setLayoutInterval(Seconds(store.getDoubleValueForKey(WebPreferencesKey::layoutIntervalKey())));3288 settings.setMaxParseDuration(store.getDoubleValueForKey(WebPreferencesKey::maxParseDurationKey()));3289 3290 settings.setEnableInheritURIQueryComponent(store.getBoolValueForKey(WebPreferencesKey::enableInheritURIQueryComponentKey()));3291 3292 auto userInterfaceDirectionPolicyCandidate = static_cast<WebCore::UserInterfaceDirectionPolicy>(store.getUInt32ValueForKey(WebPreferencesKey::userInterfaceDirectionPolicyKey()));3293 if (userInterfaceDirectionPolicyCandidate == WebCore::UserInterfaceDirectionPolicy::Content || userInterfaceDirectionPolicyCandidate == WebCore::UserInterfaceDirectionPolicy::System)3294 settings.setUserInterfaceDirectionPolicy(userInterfaceDirectionPolicyCandidate);3295 TextDirection systemLayoutDirectionCandidate = static_cast<TextDirection>(store.getUInt32ValueForKey(WebPreferencesKey::systemLayoutDirectionKey()));3296 if (systemLayoutDirectionCandidate == WebCore::LTR || systemLayoutDirectionCandidate == WebCore::RTL)3297 settings.setSystemLayoutDirection(systemLayoutDirectionCandidate);3298 3299 #if ENABLE(APPLE_PAY)3300 settings.setApplePayEnabled(store.getBoolValueForKey(WebPreferencesKey::applePayEnabledKey()));3301 settings.setApplePayCapabilityDisclosureAllowed(store.getBoolValueForKey(WebPreferencesKey::applePayCapabilityDisclosureAllowedKey()));3302 #endif3303 3304 #if PLATFORM(IOS)3305 settings.setUseImageDocumentForSubframePDF(true);3306 #endif3307 3308 #if ENABLE(DATA_DETECTION)3309 settings.setDataDetectorTypes(static_cast<DataDetectorTypes>(store.getUInt32ValueForKey(WebPreferencesKey::dataDetectorTypesKey())));3310 #endif3311 #if ENABLE(GAMEPAD)3312 RuntimeEnabledFeatures::sharedFeatures().setGamepadsEnabled(store.getBoolValueForKey(WebPreferencesKey::gamepadsEnabledKey()));3313 #endif3314 3315 #if ENABLE(SERVICE_CONTROLS)3316 settings.setServiceControlsEnabled(store.getBoolValueForKey(WebPreferencesKey::serviceControlsEnabledKey()));3317 #endif3318 3319 RuntimeEnabledFeatures::sharedFeatures().setCacheAPIEnabled(store.getBoolValueForKey(WebPreferencesKey::cacheAPIEnabledKey()));3320 RuntimeEnabledFeatures::sharedFeatures().setFetchAPIEnabled(store.getBoolValueForKey(WebPreferencesKey::fetchAPIEnabledKey()));3321 3322 #if ENABLE(DOWNLOAD_ATTRIBUTE)3323 RuntimeEnabledFeatures::sharedFeatures().setDownloadAttributeEnabled(store.getBoolValueForKey(WebPreferencesKey::downloadAttributeEnabledKey()));3324 #endif3325 3326 RuntimeEnabledFeatures::sharedFeatures().setShadowDOMEnabled(store.getBoolValueForKey(WebPreferencesKey::shadowDOMEnabledKey()));3327 3328 RuntimeEnabledFeatures::sharedFeatures().setInteractiveFormValidationEnabled(store.getBoolValueForKey(WebPreferencesKey::interactiveFormValidationEnabledKey()));3329 3330 // Experimental Features.3331 3332 RuntimeEnabledFeatures::sharedFeatures().setCSSGridLayoutEnabled(store.getBoolValueForKey(WebPreferencesKey::cssGridLayoutEnabledKey()));3333 3334 RuntimeEnabledFeatures::sharedFeatures().setCustomElementsEnabled(store.getBoolValueForKey(WebPreferencesKey::customElementsEnabledKey()));3335 3336 RuntimeEnabledFeatures::sharedFeatures().setDataTransferItemsEnabled(store.getBoolValueForKey(WebPreferencesKey::dataTransferItemsEnabledKey()));3337 3338 DeprecatedGlobalSettings::setCustomPasteboardDataEnabled(store.getBoolValueForKey(WebPreferencesKey::customPasteboardDataEnabledKey()));3339 3340 #if ENABLE(ATTACHMENT_ELEMENT)3341 RuntimeEnabledFeatures::sharedFeatures().setAttachmentElementEnabled(store.getBoolValueForKey(WebPreferencesKey::attachmentElementEnabledKey()));3342 #endif3343 3344 #if ENABLE(WEBGL2)3345 RuntimeEnabledFeatures::sharedFeatures().setWebGL2Enabled(store.getBoolValueForKey(WebPreferencesKey::webGL2EnabledKey()));3346 #endif3347 3348 #if ENABLE(WEBGPU)3349 RuntimeEnabledFeatures::sharedFeatures().setWebGPUEnabled(store.getBoolValueForKey(WebPreferencesKey::webGPUEnabledKey()));3350 #endif3351 3352 settings.setSpringTimingFunctionEnabled(store.getBoolValueForKey(WebPreferencesKey::springTimingFunctionEnabledKey()));3353 3354 settings.setConstantPropertiesEnabled(store.getBoolValueForKey(WebPreferencesKey::constantPropertiesEnabledKey()));3355 3356 settings.setViewportFitEnabled(store.getBoolValueForKey(WebPreferencesKey::viewportFitEnabledKey()));3357 3358 settings.setVisualViewportEnabled(store.getBoolValueForKey(WebPreferencesKey::visualViewportEnabledKey()));3359 3360 settings.setInputEventsEnabled(store.getBoolValueForKey(WebPreferencesKey::inputEventsEnabledKey()));3361 RuntimeEnabledFeatures::sharedFeatures().setInputEventsEnabled(store.getBoolValueForKey(WebPreferencesKey::inputEventsEnabledKey()));3362 3363 RuntimeEnabledFeatures::sharedFeatures().setModernMediaControlsEnabled(store.getBoolValueForKey(WebPreferencesKey::modernMediaControlsEnabledKey()));3364 3365 #if ENABLE(ENCRYPTED_MEDIA)3366 RuntimeEnabledFeatures::sharedFeatures().setEncryptedMediaAPIEnabled(store.getBoolValueForKey(WebPreferencesKey::encryptedMediaAPIEnabledKey()));3367 #endif3368 3369 #if ENABLE(INTERSECTION_OBSERVER)3370 RuntimeEnabledFeatures::sharedFeatures().setIntersectionObserverEnabled(store.getBoolValueForKey(WebPreferencesKey::intersectionObserverEnabledKey()));3371 #endif3372 3373 RuntimeEnabledFeatures::sharedFeatures().setDisplayContentsEnabled(store.getBoolValueForKey(WebPreferencesKey::displayContentsEnabledKey()));3374 RuntimeEnabledFeatures::sharedFeatures().setUserTimingEnabled(store.getBoolValueForKey(WebPreferencesKey::userTimingEnabledKey()));3375 RuntimeEnabledFeatures::sharedFeatures().setResourceTimingEnabled(store.getBoolValueForKey(WebPreferencesKey::resourceTimingEnabledKey()));3376 RuntimeEnabledFeatures::sharedFeatures().setLinkPreloadEnabled(store.getBoolValueForKey(WebPreferencesKey::linkPreloadEnabledKey()));3377 RuntimeEnabledFeatures::sharedFeatures().setMediaPreloadingEnabled(store.getBoolValueForKey(WebPreferencesKey::mediaPreloadingEnabledKey()));3378 RuntimeEnabledFeatures::sharedFeatures().setCredentialManagementEnabled(store.getBoolValueForKey(WebPreferencesKey::credentialManagementEnabledKey()));3379 RuntimeEnabledFeatures::sharedFeatures().setIsSecureContextAttributeEnabled(store.getBoolValueForKey(WebPreferencesKey::isSecureContextAttributeEnabledKey()));3380 RuntimeEnabledFeatures::sharedFeatures().setDirectoryUploadEnabled(store.getBoolValueForKey(WebPreferencesKey::directoryUploadEnabledKey()));3381 RuntimeEnabledFeatures::sharedFeatures().setWebVREnabled(store.getBoolValueForKey(WebPreferencesKey::webVREnabledKey()));3382 3073 3383 3074 bool processSuppressionEnabled = store.getBoolValueForKey(WebPreferencesKey::pageVisibilityBasedProcessSuppressionEnabledKey()); … … 3387 3078 } 3388 3079 3389 settings.setSubresourceIntegrityEnabled(store.getBoolValueForKey(WebPreferencesKey::subresourceIntegrityEnabledKey())); 3390 3391 #if ENABLE(BEACON_API) 3392 settings.setBeaconAPIEnabled(store.getBoolValueForKey(WebPreferencesKey::beaconAPIEnabledKey())); 3393 #endif 3394 3080 #if PLATFORM(COCOA) 3081 m_pdfPluginEnabled = store.getBoolValueForKey(WebPreferencesKey::pdfPluginEnabledKey()); 3082 #endif 3395 3083 #if ENABLE(PAYMENT_REQUEST) 3396 3084 settings.setPaymentRequestEnabled(store.getBoolValueForKey(WebPreferencesKey::applePayEnabledKey())); 3397 3085 #endif 3398 3086 3399 settings.setStorageAccessAPIEnabled(store.getBoolValueForKey(WebPreferencesKey::storageAccessAPIEnabledKey())); 3400 3401 platformPreferencesDidChange(store); 3402 3403 if (m_drawingArea) 3404 m_drawingArea->updatePreferences(store); 3087 // FIXME: This is both a RuntimeEnabledFeatures (generated) and a setting. It should pick one. 3088 settings.setInteractiveFormValidationEnabled(store.getBoolValueForKey(WebPreferencesKey::interactiveFormValidationEnabledKey())); 3405 3089 3406 3090 #if PLATFORM(IOS) … … 3408 3092 m_viewportConfiguration.setCanIgnoreScalingConstraints(m_ignoreViewportScalingConstraints); 3409 3093 setForceAlwaysUserScalable(m_forceAlwaysUserScalable || store.getBoolValueForKey(WebPreferencesKey::forceAlwaysUserScalableKey())); 3410 #endif 3411 settings.setLargeImageAsyncDecodingEnabled(store.getBoolValueForKey(WebPreferencesKey::largeImageAsyncDecodingEnabledKey())); 3412 settings.setAnimatedImageAsyncDecodingEnabled(store.getBoolValueForKey(WebPreferencesKey::animatedImageAsyncDecodingEnabledKey())); 3413 settings.setShouldSuppressTextInputFromEditingDuringProvisionalNavigation(store.getBoolValueForKey(WebPreferencesKey::shouldSuppressTextInputFromEditingDuringProvisionalNavigationKey())); 3414 settings.setMediaContentTypesRequiringHardwareSupport(store.getStringValueForKey(WebPreferencesKey::mediaContentTypesRequiringHardwareSupportKey())); 3415 settings.setAllowMediaContentTypesRequiringHardwareSupportAsFallback(store.getBoolValueForKey(WebPreferencesKey::allowMediaContentTypesRequiringHardwareSupportAsFallbackKey())); 3416 3417 #if ENABLE(LEGACY_ENCRYPTED_MEDIA) 3418 RuntimeEnabledFeatures::sharedFeatures().setLegacyEncryptedMediaAPIEnabled(store.getBoolValueForKey(WebPreferencesKey::legacyEncryptedMediaAPIEnabledKey())); 3419 #endif 3420 3421 RuntimeEnabledFeatures::sharedFeatures().setInspectorAdditionsEnabled(store.getBoolValueForKey(WebPreferencesKey::inspectorAdditionsEnabledKey())); 3094 3095 settings.setUseImageDocumentForSubframePDF(true); 3096 DeprecatedGlobalSettings::setAVKitEnabled(true); 3097 #endif 3098 3099 if (m_drawingArea) 3100 m_drawingArea->updatePreferences(store); 3422 3101 } 3423 3102 -
trunk/Source/WebKit/WebProcess/WebPage/WebPage.h
r224068 r224077 1133 1133 1134 1134 void preferencesDidChange(const WebPreferencesStore&); 1135 void platformPreferencesDidChange(const WebPreferencesStore&);1136 1135 void updatePreferences(const WebPreferencesStore&); 1136 void updatePreferencesGenerated(const WebPreferencesStore&); 1137 1137 1138 1138 void didReceivePolicyDecision(uint64_t frameID, uint64_t listenerID, WebCore::PolicyAction, uint64_t navigationID, const DownloadID&, WebsitePolicies&&); -
trunk/Source/WebKit/WebProcess/WebPage/gtk/WebPageGtk.cpp
r221349 r224077 119 119 #endif 120 120 121 void WebPage::platformPreferencesDidChange(const WebPreferencesStore&)122 {123 notImplemented();124 }125 126 121 bool WebPage::performDefaultBehaviorForKeyEvent(const WebKeyboardEvent& keyboardEvent) 127 122 { -
trunk/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm
r224068 r224077 148 148 send(Messages::WebPageProxy::RegisterWebProcessAccessibilityToken(dataToken)); 149 149 } 150 151 void WebPage::platformPreferencesDidChange(const WebPreferencesStore&)152 {153 notImplemented();154 }155 150 156 151 static void computeEditableRootHasContentAndPlainText(const VisibleSelection& selection, EditorState::PostLayoutData& data) -
trunk/Source/WebKit/WebProcess/WebPage/mac/WebPageMac.mm
r223644 r224077 183 183 } 184 184 185 void WebPage::platformPreferencesDidChange(const WebPreferencesStore& store)186 {187 }188 189 185 bool WebPage::shouldUsePDFPlugin() const 190 186 { -
trunk/Source/WebKit/WebProcess/WebPage/win/WebPageWin.cpp
r223262 r224077 64 64 } 65 65 66 void WebPage::platformPreferencesDidChange(const WebPreferencesStore&)67 {68 notImplemented();69 }70 71 66 bool WebPage::performDefaultBehaviorForKeyEvent(const WebKeyboardEvent& keyboardEvent) 72 67 { -
trunk/Source/WebKit/WebProcess/WebPage/wpe/WebPageWPE.cpp
r216497 r224077 50 50 } 51 51 52 void WebPage::platformPreferencesDidChange(const WebPreferencesStore& store)53 {54 notImplemented();55 }56 57 52 bool WebPage::performDefaultBehaviorForKeyEvent(const WebKeyboardEvent&) 58 53 {
Note: See TracChangeset
for help on using the changeset viewer.