WebKit Bugzilla
Attachment 370133 Details for
Bug 197943
: Add a website policy to disable the legacy -webkit-overflow-scrolling:touch behavior
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-197943-20190517202318.patch (text/plain), 26.58 KB, created by
Antoine Quint
on 2019-05-17 12:23:28 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Antoine Quint
Created:
2019-05-17 12:23:28 PDT
Size:
26.58 KB
patch
obsolete
>Subversion Revision: 245473 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index fb37c9d8f8d49784a06bd39c8004a478feba3619..43cf446f3ac1040d01139a3b487ac079e26946c1 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,20 @@ >+2019-05-17 Antoine Quint <graouts@apple.com> >+ >+ Add a website policy to disable the legacy -webkit-overflow-scrolling:touch behavior >+ https://bugs.webkit.org/show_bug.cgi?id=197943 >+ <rdar://problem/49078202> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Tests: fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode.html >+ platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode.html >+ >+ * css/parser/CSSParserContext.cpp: >+ (WebCore::CSSParserContext::CSSParserContext): >+ * loader/DocumentLoader.h: >+ (WebCore::DocumentLoader::legacyOverflowScrollingTouchPolicy const): >+ (WebCore::DocumentLoader::setLegacyOverflowScrollingTouchPolicy): >+ > 2019-05-17 Wenson Hsieh <wenson_hsieh@apple.com> > > Fix a typo in some user agent string logic >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 57d00f4ec8530695b21622a539b0956113177307..d725ce567bda4720ba3707d124f3dbeade829aba 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,23 @@ >+2019-05-17 Antoine Quint <graouts@apple.com> >+ >+ Add a website policy to disable the legacy -webkit-overflow-scrolling:touch behavior >+ https://bugs.webkit.org/show_bug.cgi?id=197943 >+ <rdar://problem/49078202> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * Shared/WebsiteLegacyOverflowScrollingTouchPolicy.h: Added. >+ * Shared/WebsitePoliciesData.cpp: >+ (WebKit::WebsitePoliciesData::encode const): >+ (WebKit::WebsitePoliciesData::decode): >+ (WebKit::WebsitePoliciesData::applyToDocumentLoader): >+ * Shared/WebsitePoliciesData.h: >+ * UIProcess/API/APIWebsitePolicies.cpp: >+ (API::WebsitePolicies::copy const): >+ (API::WebsitePolicies::data): >+ * UIProcess/API/APIWebsitePolicies.h: >+ * WebKit.xcodeproj/project.pbxproj: >+ > 2019-05-17 Commit Queue <commit-queue@webkit.org> > > Unreviewed, rolling out r245401. >diff --git a/Source/WebCore/css/parser/CSSParserContext.cpp b/Source/WebCore/css/parser/CSSParserContext.cpp >index 29f231c44225f8aa682d17330cbffa22e51ad4ab..7537188cb93d301c824a788d53953eaec034971b 100644 >--- a/Source/WebCore/css/parser/CSSParserContext.cpp >+++ b/Source/WebCore/css/parser/CSSParserContext.cpp >@@ -27,6 +27,7 @@ > #include "CSSParserContext.h" > > #include "Document.h" >+#include "DocumentLoader.h" > #include "Page.h" > #include "RuntimeEnabledFeatures.h" > #include "Settings.h" >@@ -60,6 +61,12 @@ CSSParserContext::CSSParserContext(const Document& document, const URL& sheetBas > #endif > #if ENABLE(OVERFLOW_SCROLLING_TOUCH) > legacyOverflowScrollingTouchEnabled = document.settings().legacyOverflowScrollingTouchEnabled(); >+ // The legacy -webkit-overflow-scrolling: touch behavior may have been disabled through the website policy, >+ // in that case we want to disable the legacy behavior regardless of what the setting says. >+ if (auto* loader = document.loader()) { >+ if (loader->legacyOverflowScrollingTouchPolicy() == LegacyOverflowScrollingTouchPolicy::Disable) >+ legacyOverflowScrollingTouchEnabled = false; >+ } > #endif > springTimingFunctionEnabled = document.settings().springTimingFunctionEnabled(); > constantPropertiesEnabled = document.settings().constantPropertiesEnabled(); >diff --git a/Source/WebCore/loader/DocumentLoader.h b/Source/WebCore/loader/DocumentLoader.h >index b1445e7bb92c5b6064fbe71f567a4892c4eb6195..3be1956d8aa3dda2ee12d2e4302e0b4086cadfa4 100644 >--- a/Source/WebCore/loader/DocumentLoader.h >+++ b/Source/WebCore/loader/DocumentLoader.h >@@ -131,6 +131,12 @@ enum class SimulatedMouseEventsDispatchPolicy : uint8_t { > Deny, > }; > >+enum class LegacyOverflowScrollingTouchPolicy : uint8_t { >+ Default, >+ Disable, >+ Enable, >+}; >+ > class DocumentLoader > : public RefCounted<DocumentLoader> > , public FrameDestructionObserver >@@ -313,6 +319,9 @@ public: > SimulatedMouseEventsDispatchPolicy simulatedMouseEventsDispatchPolicy() const { return m_simulatedMouseEventsDispatchPolicy; } > void setSimulatedMouseEventsDispatchPolicy(SimulatedMouseEventsDispatchPolicy policy) { m_simulatedMouseEventsDispatchPolicy = policy; } > >+ LegacyOverflowScrollingTouchPolicy legacyOverflowScrollingTouchPolicy() const { return m_legacyOverflowScrollingTouchPolicy; } >+ void setLegacyOverflowScrollingTouchPolicy(LegacyOverflowScrollingTouchPolicy policy) { m_legacyOverflowScrollingTouchPolicy = policy; } >+ > void addSubresourceLoader(ResourceLoader*); > void removeSubresourceLoader(LoadCompletionType, ResourceLoader*); > void addPlugInStreamLoader(ResourceLoader&); >@@ -596,6 +605,7 @@ private: > MetaViewportPolicy m_metaViewportPolicy { MetaViewportPolicy::Default }; > MediaSourcePolicy m_mediaSourcePolicy { MediaSourcePolicy::Default }; > SimulatedMouseEventsDispatchPolicy m_simulatedMouseEventsDispatchPolicy { SimulatedMouseEventsDispatchPolicy::Default }; >+ LegacyOverflowScrollingTouchPolicy m_legacyOverflowScrollingTouchPolicy { LegacyOverflowScrollingTouchPolicy::Default }; > > #if ENABLE(SERVICE_WORKER) > Optional<ServiceWorkerRegistrationData> m_serviceWorkerRegistrationData; >diff --git a/Source/WebKit/Shared/WebsiteLegacyOverflowScrollingTouchPolicy.h b/Source/WebKit/Shared/WebsiteLegacyOverflowScrollingTouchPolicy.h >new file mode 100644 >index 0000000000000000000000000000000000000000..e0d26dd5fa526258a3217d6f0753609a12371473 >--- /dev/null >+++ b/Source/WebKit/Shared/WebsiteLegacyOverflowScrollingTouchPolicy.h >@@ -0,0 +1,51 @@ >+/* >+ * Copyright (C) 2019 Apple Inc. All rights reserved. >+ * >+ * Redistribution and use in source and binary forms, with or without >+ * modification, are permitted provided that the following conditions >+ * are met: >+ * 1. Redistributions of source code must retain the above copyright >+ * notice, this list of conditions and the following disclaimer. >+ * 2. Redistributions in binary form must reproduce the above copyright >+ * notice, this list of conditions and the following disclaimer in the >+ * documentation and/or other materials provided with the distribution. >+ * >+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' >+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, >+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR >+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS >+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR >+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF >+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS >+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN >+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) >+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF >+ * THE POSSIBILITY OF SUCH DAMAGE. >+ */ >+ >+#pragma once >+ >+#include <wtf/Forward.h> >+ >+namespace WebKit { >+ >+enum class WebsiteLegacyOverflowScrollingTouchPolicy : uint8_t { >+ Default, >+ Disable, >+ Enable >+}; >+ >+} >+ >+namespace WTF { >+ >+template<> struct EnumTraits<WebKit::WebsiteLegacyOverflowScrollingTouchPolicy> { >+ using values = EnumValues< >+ WebKit::WebsiteLegacyOverflowScrollingTouchPolicy, >+ WebKit::WebsiteLegacyOverflowScrollingTouchPolicy::Default, >+ WebKit::WebsiteLegacyOverflowScrollingTouchPolicy::Disable, >+ WebKit::WebsiteLegacyOverflowScrollingTouchPolicy::Enable >+ >; >+}; >+ >+} // namespace WTF >diff --git a/Source/WebKit/Shared/WebsitePoliciesData.cpp b/Source/WebKit/Shared/WebsitePoliciesData.cpp >index 5a54860065e128643e828e252f2d0ba9cdb85224..a30bdb42a44f3685a245ca3fda1a5b7697b33cd0 100644 >--- a/Source/WebKit/Shared/WebsitePoliciesData.cpp >+++ b/Source/WebKit/Shared/WebsitePoliciesData.cpp >@@ -51,6 +51,7 @@ void WebsitePoliciesData::encode(IPC::Encoder& encoder) const > encoder << metaViewportPolicy; > encoder << mediaSourcePolicy; > encoder << simulatedMouseEventsDispatchPolicy; >+ encoder << legacyOverflowScrollingTouchPolicy; > } > > Optional<WebsitePoliciesData> WebsitePoliciesData::decode(IPC::Decoder& decoder) >@@ -122,6 +123,11 @@ Optional<WebsitePoliciesData> WebsitePoliciesData::decode(IPC::Decoder& decoder) > if (!simulatedMouseEventsDispatchPolicy) > return WTF::nullopt; > >+ Optional<WebsiteLegacyOverflowScrollingTouchPolicy> legacyOverflowScrollingTouchPolicy; >+ decoder >> legacyOverflowScrollingTouchPolicy; >+ if (!legacyOverflowScrollingTouchPolicy) >+ return WTF::nullopt; >+ > return { { > WTFMove(*contentBlockersEnabled), > WTFMove(*allowedAutoplayQuirks), >@@ -138,6 +144,7 @@ Optional<WebsitePoliciesData> WebsitePoliciesData::decode(IPC::Decoder& decoder) > WTFMove(*metaViewportPolicy), > WTFMove(*mediaSourcePolicy), > WTFMove(*simulatedMouseEventsDispatchPolicy), >+ WTFMove(*legacyOverflowScrollingTouchPolicy), > } }; > } > >@@ -236,6 +243,18 @@ void WebsitePoliciesData::applyToDocumentLoader(WebsitePoliciesData&& websitePol > break; > } > >+ switch (websitePolicies.legacyOverflowScrollingTouchPolicy) { >+ case WebsiteLegacyOverflowScrollingTouchPolicy::Default: >+ documentLoader.setLegacyOverflowScrollingTouchPolicy(WebCore::LegacyOverflowScrollingTouchPolicy::Default); >+ break; >+ case WebsiteLegacyOverflowScrollingTouchPolicy::Disable: >+ documentLoader.setLegacyOverflowScrollingTouchPolicy(WebCore::LegacyOverflowScrollingTouchPolicy::Disable); >+ break; >+ case WebsiteLegacyOverflowScrollingTouchPolicy::Enable: >+ documentLoader.setLegacyOverflowScrollingTouchPolicy(WebCore::LegacyOverflowScrollingTouchPolicy::Enable); >+ break; >+ } >+ > if (websitePolicies.websiteDataStoreParameters) { > if (auto* frame = documentLoader.frame()) { > if (auto* page = frame->page()) >diff --git a/Source/WebKit/Shared/WebsitePoliciesData.h b/Source/WebKit/Shared/WebsitePoliciesData.h >index 6a02fca8e10560acdac6f7a5bbf34d9190afd945..3512254849c048858ce96763186f8f0c296a4fa9 100644 >--- a/Source/WebKit/Shared/WebsitePoliciesData.h >+++ b/Source/WebKit/Shared/WebsitePoliciesData.h >@@ -28,6 +28,7 @@ > #include "WebsiteAutoplayPolicy.h" > #include "WebsiteAutoplayQuirk.h" > #include "WebsiteDataStoreParameters.h" >+#include "WebsiteLegacyOverflowScrollingTouchPolicy.h" > #include "WebsiteMediaSourcePolicy.h" > #include "WebsiteMetaViewportPolicy.h" > #include "WebsitePopUpPolicy.h" >@@ -65,6 +66,7 @@ struct WebsitePoliciesData { > WebsiteMetaViewportPolicy metaViewportPolicy { WebsiteMetaViewportPolicy::Default }; > WebsiteMediaSourcePolicy mediaSourcePolicy { WebsiteMediaSourcePolicy::Default }; > WebsiteSimulatedMouseEventsDispatchPolicy simulatedMouseEventsDispatchPolicy { WebsiteSimulatedMouseEventsDispatchPolicy::Default }; >+ WebsiteLegacyOverflowScrollingTouchPolicy legacyOverflowScrollingTouchPolicy { WebsiteLegacyOverflowScrollingTouchPolicy::Default }; > > void encode(IPC::Encoder&) const; > static Optional<WebsitePoliciesData> decode(IPC::Decoder&); >diff --git a/Source/WebKit/UIProcess/API/APIWebsitePolicies.cpp b/Source/WebKit/UIProcess/API/APIWebsitePolicies.cpp >index 99e830ce8d4d613cf9da850b21ca812819823690..4faf815a0d01cfee6d98a48da3aec4aa3d3f25d0 100644 >--- a/Source/WebKit/UIProcess/API/APIWebsitePolicies.cpp >+++ b/Source/WebKit/UIProcess/API/APIWebsitePolicies.cpp >@@ -60,6 +60,8 @@ Ref<WebsitePolicies> WebsitePolicies::copy() const > policies->setMetaViewportPolicy(m_metaViewportPolicy); > policies->setMediaSourcePolicy(m_mediaSourcePolicy); > policies->setSimulatedMouseEventsDispatchPolicy(m_simulatedMouseEventsDispatchPolicy); >+ policies->setLegacyOverflowScrollingTouchPolicy(m_legacyOverflowScrollingTouchPolicy); >+ > Vector<WebCore::HTTPHeaderField> customHeaderFields; > customHeaderFields.reserveInitialCapacity(m_customHeaderFields.size()); > for (auto& field : m_customHeaderFields) >@@ -97,6 +99,7 @@ WebKit::WebsitePoliciesData WebsitePolicies::data() > m_metaViewportPolicy, > m_mediaSourcePolicy, > m_simulatedMouseEventsDispatchPolicy, >+ m_legacyOverflowScrollingTouchPolicy, > }; > } > >diff --git a/Source/WebKit/UIProcess/API/APIWebsitePolicies.h b/Source/WebKit/UIProcess/API/APIWebsitePolicies.h >index 4d49269a84ad8d8d454fa670a375aec4fddf6a70..5ebac1c8bfa695e9fb21b011aac0beef730a0945 100644 >--- a/Source/WebKit/UIProcess/API/APIWebsitePolicies.h >+++ b/Source/WebKit/UIProcess/API/APIWebsitePolicies.h >@@ -29,6 +29,7 @@ > #include "WebCompatibilityMode.h" > #include "WebsiteAutoplayPolicy.h" > #include "WebsiteAutoplayQuirk.h" >+#include "WebsiteLegacyOverflowScrollingTouchPolicy.h" > #include "WebsiteMediaSourcePolicy.h" > #include "WebsiteMetaViewportPolicy.h" > #include "WebsitePopUpPolicy.h" >@@ -101,6 +102,9 @@ public: > WebKit::WebsiteSimulatedMouseEventsDispatchPolicy simulatedMouseEventsDispatchPolicy() const { return m_simulatedMouseEventsDispatchPolicy; } > void setSimulatedMouseEventsDispatchPolicy(WebKit::WebsiteSimulatedMouseEventsDispatchPolicy policy) { m_simulatedMouseEventsDispatchPolicy = policy; } > >+ WebKit::WebsiteLegacyOverflowScrollingTouchPolicy legacyOverflowScrollingTouchPolicy() const { return m_legacyOverflowScrollingTouchPolicy; } >+ void setLegacyOverflowScrollingTouchPolicy(WebKit::WebsiteLegacyOverflowScrollingTouchPolicy policy) { m_legacyOverflowScrollingTouchPolicy = policy; } >+ > bool allowSiteSpecificQuirksToOverrideCompatibilityMode() const { return m_allowSiteSpecificQuirksToOverrideCompatibilityMode; } > void setAllowSiteSpecificQuirksToOverrideCompatibilityMode(bool value) { m_allowSiteSpecificQuirksToOverrideCompatibilityMode = value; } > >@@ -126,6 +130,7 @@ private: > WebKit::WebsiteMetaViewportPolicy m_metaViewportPolicy { WebKit::WebsiteMetaViewportPolicy::Default }; > WebKit::WebsiteMediaSourcePolicy m_mediaSourcePolicy { WebKit::WebsiteMediaSourcePolicy::Default }; > WebKit::WebsiteSimulatedMouseEventsDispatchPolicy m_simulatedMouseEventsDispatchPolicy { WebKit::WebsiteSimulatedMouseEventsDispatchPolicy::Default }; >+ WebKit::WebsiteLegacyOverflowScrollingTouchPolicy m_legacyOverflowScrollingTouchPolicy { WebKit::WebsiteLegacyOverflowScrollingTouchPolicy::Default }; > bool m_allowSiteSpecificQuirksToOverrideCompatibilityMode { false }; > WTF::String m_applicationNameForUserAgentWithModernCompatibility; > }; >diff --git a/Source/WebKit/WebKit.xcodeproj/project.pbxproj b/Source/WebKit/WebKit.xcodeproj/project.pbxproj >index 26c05c7469e68f7fb24c47086cab523fb42536e0..92ecb19f29befb57b3c783ec2df7570e66dc3ae1 100644 >--- a/Source/WebKit/WebKit.xcodeproj/project.pbxproj >+++ b/Source/WebKit/WebKit.xcodeproj/project.pbxproj >@@ -1115,6 +1115,7 @@ > 6BE969CB1E54D4CF008B7483 /* ResourceLoadStatisticsClassifierCocoa.h in Headers */ = {isa = PBXBuildFile; fileRef = 6BE969C91E54D4CF008B7483 /* ResourceLoadStatisticsClassifierCocoa.h */; }; > 6BE969CD1E54E054008B7483 /* ResourceLoadStatisticsClassifier.h in Headers */ = {isa = PBXBuildFile; fileRef = 6BE969CC1E54E054008B7483 /* ResourceLoadStatisticsClassifier.h */; }; > 6EE849C81368D9390038D481 /* WKInspectorPrivateMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 6EE849C61368D92D0038D481 /* WKInspectorPrivateMac.h */; settings = {ATTRIBUTES = (Private, ); }; }; >+ 711725A9228D564300018514 /* WebsiteLegacyOverflowScrollingTouchPolicy.h in Headers */ = {isa = PBXBuildFile; fileRef = 711725A8228D563A00018514 /* WebsiteLegacyOverflowScrollingTouchPolicy.h */; }; > 71FB810B2260627E00323677 /* WebsiteSimulatedMouseEventsDispatchPolicy.h in Headers */ = {isa = PBXBuildFile; fileRef = 71FB810A2260627A00323677 /* WebsiteSimulatedMouseEventsDispatchPolicy.h */; }; > 728E86F11795188C0087879E /* WebColorPickerMac.h in Headers */ = {isa = PBXBuildFile; fileRef = 728E86EF1795188C0087879E /* WebColorPickerMac.h */; }; > 75A8D2C8187CCFAB00C39C9E /* WKWebsiteDataStore.h in Headers */ = {isa = PBXBuildFile; fileRef = 75A8D2C4187CCF9F00C39C9E /* WKWebsiteDataStore.h */; settings = {ATTRIBUTES = (Public, ); }; }; >@@ -3600,6 +3601,7 @@ > 6BE969CC1E54E054008B7483 /* ResourceLoadStatisticsClassifier.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ResourceLoadStatisticsClassifier.h; sourceTree = "<group>"; }; > 6D8A91A511F0EFD100DD01FE /* com.apple.WebProcess.sb.in */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = com.apple.WebProcess.sb.in; path = WebProcess/com.apple.WebProcess.sb.in; sourceTree = "<group>"; }; > 6EE849C61368D92D0038D481 /* WKInspectorPrivateMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WKInspectorPrivateMac.h; path = mac/WKInspectorPrivateMac.h; sourceTree = "<group>"; }; >+ 711725A8228D563A00018514 /* WebsiteLegacyOverflowScrollingTouchPolicy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebsiteLegacyOverflowScrollingTouchPolicy.h; sourceTree = "<group>"; }; > 71FB810A2260627A00323677 /* WebsiteSimulatedMouseEventsDispatchPolicy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebsiteSimulatedMouseEventsDispatchPolicy.h; sourceTree = "<group>"; }; > 728E86EF1795188C0087879E /* WebColorPickerMac.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebColorPickerMac.h; sourceTree = "<group>"; }; > 728E86F01795188C0087879E /* WebColorPickerMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebColorPickerMac.mm; sourceTree = "<group>"; }; >@@ -5272,6 +5274,7 @@ > 5C8DD3811FE455CA00F2A556 /* WebsiteAutoplayQuirk.h */, > 511F7D3F1EB1BCEE00E47B83 /* WebsiteDataStoreParameters.cpp */, > 511F7D401EB1BCEE00E47B83 /* WebsiteDataStoreParameters.h */, >+ 711725A8228D563A00018514 /* WebsiteLegacyOverflowScrollingTouchPolicy.h */, > F4CB09E4225D5A0300891487 /* WebsiteMediaSourcePolicy.h */, > F430E941224732A9005FE053 /* WebsiteMetaViewportPolicy.h */, > 5C3AEA8E1FE1F1DF002318D3 /* WebsitePoliciesData.cpp */, >@@ -9761,6 +9764,7 @@ > 1A4832D11A9BDC2F008B4DFE /* WebsiteDataRecord.h in Headers */, > 1A53C2AA1A325730004E8C70 /* WebsiteDataStore.h in Headers */, > 511F7D411EB1BCF500E47B83 /* WebsiteDataStoreParameters.h in Headers */, >+ 711725A9228D564300018514 /* WebsiteLegacyOverflowScrollingTouchPolicy.h in Headers */, > F4CB09E5225D5A0900891487 /* WebsiteMediaSourcePolicy.h in Headers */, > F430E9422247335F005FE053 /* WebsiteMetaViewportPolicy.h in Headers */, > 0EDE85032004E75D00030560 /* WebsitePopUpPolicy.h in Headers */, >diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index e15385eb3ef3e68be9dc2ba0f7fef2d3501f4d14..e62e3aa544e69f302faa326a4fc1d070c7873424 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,17 @@ >+2019-05-17 Antoine Quint <graouts@apple.com> >+ >+ Add a website policy to disable the legacy -webkit-overflow-scrolling:touch behavior >+ https://bugs.webkit.org/show_bug.cgi?id=197943 >+ <rdar://problem/49078202> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode-expected.html: Added. >+ * fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode.html: Added. >+ * platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode-expected.txt: Added. >+ * platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode.html: Added. >+ * platform/ios/TestExpectations: Skip the new tests since they depend on code in WebKitAdditions. >+ > 2019-05-17 Shawn Roberts <sroberts@apple.com> > > media/controls-after-reload.html failing on iOS after unskip >diff --git a/LayoutTests/fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode-expected.html b/LayoutTests/fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode-expected.html >new file mode 100644 >index 0000000000000000000000000000000000000000..256b1d4d8716eb168e66a5330e1f86669dc605e0 >--- /dev/null >+++ b/LayoutTests/fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode-expected.html >@@ -0,0 +1,52 @@ >+<!DOCTYPE html> <!-- webkit-test-runner [ shouldUseModernCompatibilityMode=true internal:AsyncOverflowScrollingEnabled=true ] --> >+<html> >+<head> >+ <style> >+ .box { >+ position: absolute; >+ height: 200px; >+ width: 200px; >+ background-color: blue; >+ } >+ >+ .scroller { >+ margin: 60px; >+ overflow: scroll; >+ border: 1px solid black; >+ width: 220px; >+ height: 220px; >+ } >+ >+ .scrolled-contents { >+ height: 1000px; >+ } >+ >+ .outside { >+ z-index: 1; >+ top: 20px; >+ left: 20px; >+ background-color: green; >+ } >+ >+ .back { >+ z-index: 0; >+ } >+ >+ .front { >+ z-index: 2; >+ top: 120px; >+ left: 120px; >+ background-color: orange; >+ } >+ </style> >+</head> >+<body> >+ <div class="outside box"></div> >+ <div class="scroller"> >+ <div class="scrolled-contents"> >+ <div class="back box"></div> >+ <div class="front box"></div> >+ </div> >+ </div> >+</body> >+</html> >diff --git a/LayoutTests/fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode.html b/LayoutTests/fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode.html >new file mode 100644 >index 0000000000000000000000000000000000000000..619b7e428c94045e0fe4720be88abdcf8899c238 >--- /dev/null >+++ b/LayoutTests/fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode.html >@@ -0,0 +1,53 @@ >+<!DOCTYPE html> <!-- webkit-test-runner [ shouldUseModernCompatibilityMode=true internal:AsyncOverflowScrollingEnabled=true ] --> >+<html> >+<head> >+ <style> >+ .box { >+ position: absolute; >+ height: 200px; >+ width: 200px; >+ background-color: blue; >+ } >+ >+ .scroller { >+ margin: 60px; >+ overflow: scroll; >+ border: 1px solid black; >+ width: 220px; >+ height: 220px; >+ -webkit-overflow-scrolling: touch; >+ } >+ >+ .scrolled-contents { >+ height: 1000px; >+ } >+ >+ .outside { >+ z-index: 1; >+ top: 20px; >+ left: 20px; >+ background-color: green; >+ } >+ >+ .back { >+ z-index: 0; >+ } >+ >+ .front { >+ z-index: 2; >+ top: 120px; >+ left: 120px; >+ background-color: orange; >+ } >+ </style> >+</head> >+<body> >+ <div class="outside box"></div> >+ <div class="scroller"> >+ <div class="scrolled-contents"> >+ <div class="back box"></div> >+ <div class="front box"></div> >+ </div> >+ </div> >+</body> >+</html> >diff --git a/LayoutTests/platform/ios/TestExpectations b/LayoutTests/platform/ios/TestExpectations >index bc80d1299b38bfa32a788501c6348bef323624db..b5bf208c44ff671ebe74b91a0837937c79790071 100644 >--- a/LayoutTests/platform/ios/TestExpectations >+++ b/LayoutTests/platform/ios/TestExpectations >@@ -3265,6 +3265,10 @@ webkit.org/b/175678 media/W3C/video/events/event_progress.html [ Pass Failure ] > # FIXME: Unskip the following test once we have the fix for <rdar://problem/50596032>. > fast/events/ios/submit-form-target-blank-using-return-key.html > >+# These tests depend on the implementation of "modern compatibility mode" in WebKitAdditions. >+platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode.html [ Skip ] >+fast/scrolling/ipad/overflow-scrolling-touch-enabled-stacking-modern-compatibility-mode.html [ Skip ] >+ > webkit.org/b/197778 [ Debug ] webgl/2.0.0/conformance2/attribs/gl-vertexattribipointer.html [ Slow ] > > # Was unskipped, but now has missing results in iOS . Skipping on iOS only. >diff --git a/LayoutTests/platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode-expected.txt b/LayoutTests/platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode-expected.txt >new file mode 100644 >index 0000000000000000000000000000000000000000..fc8636fa109fed2b0d0697e8fd9ce8d9f07153a4 >--- /dev/null >+++ b/LayoutTests/platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode-expected.txt >@@ -0,0 +1,12 @@ >+This tests checks parsing of the '-webkit-overflow-scrolling' property. >+ >+On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". >+ >+ >+PASS test("-webkit-overflow-scrolling: auto", "-webkit-overflow-scrolling") is "" >+PASS test("-webkit-overflow-scrolling: banana", "-webkit-overflow-scrolling") is "" >+PASS test("-webkit-overflow-scrolling: touch", "-webkit-overflow-scrolling") is "" >+PASS successfullyParsed is true >+ >+TEST COMPLETE >+ >diff --git a/LayoutTests/platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode.html b/LayoutTests/platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode.html >new file mode 100644 >index 0000000000000000000000000000000000000000..dfca2a1308fcba15cc2af3bdea0a7327dbeca24b >--- /dev/null >+++ b/LayoutTests/platform/ipad/fast/css/webkit-overflow-scrolling-parsing-modern-compatibility-mode.html >@@ -0,0 +1,31 @@ >+<!DOCTYPE html> <!-- webkit-test-runner [ shouldUseModernCompatibilityMode=true ] --> >+<html> >+<head> >+<script src="../../../../resources/js-test-pre.js"></script> >+</head> >+<body> >+<p id="description"></p> >+<div id="console"></div> >+<script> >+description("This tests checks parsing of the '-webkit-overflow-scrolling' property."); >+ >+function test(declaration, property) >+{ >+ var div = document.createElement("div"); >+ div.setAttribute("style", declaration); >+ document.body.appendChild(div); >+ >+ var result = div.style.getPropertyValue(property); >+ document.body.removeChild(div); >+ return result; >+} >+ >+shouldBe('test("-webkit-overflow-scrolling: auto", "-webkit-overflow-scrolling")', '""'); >+shouldBe('test("-webkit-overflow-scrolling: banana", "-webkit-overflow-scrolling")', '""'); >+shouldBe('test("-webkit-overflow-scrolling: touch", "-webkit-overflow-scrolling")', '""'); >+ >+var successfullyParsed = true; >+</script> >+<script src="../../../../resources/js-test-post.js"></script> >+</body> >+</html>
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
bfulgham
:
review+
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 197943
:
370033
|
370110
|
370113
|
370132
| 370133