<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[245553] branches/safari-608.1.24.20-branch</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/245553">245553</a></dd>
<dt>Author</dt> <dd>kocsen_chung@apple.com</dd>
<dt>Date</dt> <dd>2019-05-20 20:21:18 -0700 (Mon, 20 May 2019)</dd>
</dl>

<h3>Log Message</h3>
<pre>Cherry-pick <a href="http://trac.webkit.org/projects/webkit/changeset/245465">r245465</a>. rdar://problem/50252398

    [iOS] Respect scrolling="no" on composited frames
    https://bugs.webkit.org/show_bug.cgi?id=197972
    <rdar://problem/50252398>

    Reviewed by Simon Fraser.

    Source/WebKit:

    * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h:
    * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm:
    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::commitStateAfterChildren):

    Disallow scrolling based on canHaveScrollbars, similar to main frame.

    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::repositionScrollingLayers):
    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::scrollView const):

    Factor into a function.

    LayoutTests:

    * fast/scrolling/ios/body-overflow-hidden-frame-expected.html:
    * fast/scrolling/ios/body-overflow-hidden-frame.html:

    Also fix overflow:hidden test so that the frame content forces composition.

    * fast/scrolling/ios/frame-scrolling-no-expected.html: Added.
    * fast/scrolling/ios/frame-scrolling-no.html: Added.

    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@245465 268f45cc-cd09-0410-ab3c-d52691b4dbfc</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#branchessafari60812420branchLayoutTestsChangeLog">branches/safari-608.1.24.20-branch/LayoutTests/ChangeLog</a></li>
<li><a href="#branchessafari60812420branchLayoutTestsfastscrollingiosbodyoverflowhiddenframeexpectedhtml">branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame-expected.html</a></li>
<li><a href="#branchessafari60812420branchLayoutTestsfastscrollingiosbodyoverflowhiddenframehtml">branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame.html</a></li>
<li><a href="#branchessafari60812420branchSourceWebKitChangeLog">branches/safari-608.1.24.20-branch/Source/WebKit/ChangeLog</a></li>
<li><a href="#branchessafari60812420branchSourceWebKitUIProcessRemoteLayerTreeiosScrollingTreeScrollingNodeDelegateIOSh">branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h</a></li>
<li><a href="#branchessafari60812420branchSourceWebKitUIProcessRemoteLayerTreeiosScrollingTreeScrollingNodeDelegateIOSmm">branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#branchessafari60812420branchLayoutTestsfastscrollingiosframescrollingnoexpectedhtml">branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no-expected.html</a></li>
<li><a href="#branchessafari60812420branchLayoutTestsfastscrollingiosframescrollingnohtml">branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="branchessafari60812420branchLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-608.1.24.20-branch/LayoutTests/ChangeLog (245552 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/LayoutTests/ChangeLog 2019-05-21 03:21:14 UTC (rev 245552)
+++ branches/safari-608.1.24.20-branch/LayoutTests/ChangeLog    2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -1,5 +1,57 @@
</span><span class="cx"> 2019-05-20  Kocsen Chung  <kocsen_chung@apple.com>
</span><span class="cx"> 
</span><ins>+        Cherry-pick r245465. rdar://problem/50252398
+
+    [iOS] Respect scrolling="no" on composited frames
+    https://bugs.webkit.org/show_bug.cgi?id=197972
+    <rdar://problem/50252398>
+    
+    Reviewed by Simon Fraser.
+    
+    Source/WebKit:
+    
+    * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h:
+    * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm:
+    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::commitStateAfterChildren):
+    
+    Disallow scrolling based on canHaveScrollbars, similar to main frame.
+    
+    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::repositionScrollingLayers):
+    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::scrollView const):
+    
+    Factor into a function.
+    
+    LayoutTests:
+    
+    * fast/scrolling/ios/body-overflow-hidden-frame-expected.html:
+    * fast/scrolling/ios/body-overflow-hidden-frame.html:
+    
+    Also fix overflow:hidden test so that the frame content forces composition.
+    
+    * fast/scrolling/ios/frame-scrolling-no-expected.html: Added.
+    * fast/scrolling/ios/frame-scrolling-no.html: Added.
+    
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@245465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2019-05-17  Antti Koivisto  <antti@apple.com>
+
+            [iOS] Respect scrolling="no" on composited frames
+            https://bugs.webkit.org/show_bug.cgi?id=197972
+            <rdar://problem/50252398>
+
+            Reviewed by Simon Fraser.
+
+            * fast/scrolling/ios/body-overflow-hidden-frame-expected.html:
+            * fast/scrolling/ios/body-overflow-hidden-frame.html:
+
+            Also fix overflow:hidden test so that the frame content forces composition.
+
+            * fast/scrolling/ios/frame-scrolling-no-expected.html: Added.
+            * fast/scrolling/ios/frame-scrolling-no.html: Added.
+
+2019-05-20  Kocsen Chung  <kocsen_chung@apple.com>
+
</ins><span class="cx">         Cherry-pick r245220. rdar://problem/50686229
</span><span class="cx"> 
</span><span class="cx">     When the set of backing-sharing layers changes, we need to issue a repaint
</span></span></pre></div>
<a id="branchessafari60812420branchLayoutTestsfastscrollingiosbodyoverflowhiddenframeexpectedhtml"></a>
<div class="modfile"><h4>Modified: branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame-expected.html (245552 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame-expected.html       2019-05-21 03:21:14 UTC (rev 245552)
+++ branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame-expected.html  2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -11,7 +11,7 @@
</span><span class="cx">     <html>
</span><span class="cx">     <style>
</span><span class="cx">     body { overflow: hidden }
</span><del>-    .scroll-content { width: 500px; height: 5000px; border: 2px solid green; }
</del><ins>+    .scroll-content { width: 500px; height: 5000px; border: 2px solid green; transform:translateZ(0) }
</ins><span class="cx">     </style>
</span><span class="cx">     <body>
</span><span class="cx">     <div class='scroll-content'>
</span></span></pre></div>
<a id="branchessafari60812420branchLayoutTestsfastscrollingiosbodyoverflowhiddenframehtml"></a>
<div class="modfile"><h4>Modified: branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame.html (245552 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame.html        2019-05-21 03:21:14 UTC (rev 245552)
+++ branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame.html   2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -32,7 +32,7 @@
</span><span class="cx">     <html>
</span><span class="cx">     <style>
</span><span class="cx">     body { overflow: hidden }
</span><del>-    .scroll-content { width: 500px; height: 5000px; border: 2px solid green; }
</del><ins>+    .scroll-content { width: 500px; height: 5000px; border: 2px solid green; transform:translateZ(0) }
</ins><span class="cx">     </style>
</span><span class="cx">     <body>
</span><span class="cx">     <div class='scroll-content'>
</span></span></pre></div>
<a id="branchessafari60812420branchLayoutTestsfastscrollingiosframescrollingnoexpectedhtmlfromrev245552branchessafari60812420branchLayoutTestsfastscrollingiosbodyoverflowhiddenframeexpectedhtml"></a>
<div class="copfile"><h4>Copied: branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no-expected.html (from rev 245552, branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame-expected.html) (0 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no-expected.html                               (rev 0)
+++ branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no-expected.html  2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -0,0 +1,24 @@
</span><ins>+<!DOCTYPE html> <!-- webkit-test-runner [ internal:AsyncOverflowScrollingEnabled=true internal:AsyncFrameScrollingEnabled=true ] -->
+<html>
+<head>
+<meta name="viewport" content="width=device-width, initial-scale=1">
+<style>
+body { overflow: hidden }
+.scroll-content { width: 500px; height: 5000px; border: 2px solid green; }
+</style>
+<body>
+<iframe scrolling="no" srcdoc="
+    <html>
+    <style>
+    .scroll-content { width: 500px; height: 5000px; border: 2px solid green; transform:translateZ(0) }
+    </style>
+    <body>
+    <div class='scroll-content'>
+    This document shouldn't be scrollable.
+    </div>
+    </body>
+    </html>
+" width=500 height=500>
+</iframe>
+</body>
+</html>
</ins></span></pre></div>
<a id="branchessafari60812420branchLayoutTestsfastscrollingiosframescrollingnohtmlfromrev245552branchessafari60812420branchLayoutTestsfastscrollingiosbodyoverflowhiddenframehtml"></a>
<div class="copfile"><h4>Copied: branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no.html (from rev 245552, branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/body-overflow-hidden-frame.html) (0 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no.html                                (rev 0)
+++ branches/safari-608.1.24.20-branch/LayoutTests/fast/scrolling/ios/frame-scrolling-no.html   2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -0,0 +1,45 @@
</span><ins>+<!DOCTYPE html> <!-- webkit-test-runner [ internal:AsyncOverflowScrollingEnabled=true internal:AsyncFrameScrollingEnabled=true ] -->
+<html>
+<head>
+<meta name="viewport" content="width=device-width, initial-scale=1">
+<script src="../../../resources/basic-gestures.js"></script>
+<style>
+body { overflow: hidden }
+.scroll-content { width: 500px; height: 5000px; border: 2px solid green; }
+</style>
+<script>
+if (window.testRunner)
+    testRunner.waitUntilDone();
+
+function waitPromise(delay)
+{
+    return new Promise(resolve => setTimeout(resolve, delay));
+}
+
+async function runTest() {
+    if (!window.testRunner)
+        return;
+
+    await touchAndDragFromPointToPoint(150, 300, 150, 150);
+    await liftUpAtPoint(150, 150);
+    await waitPromise(50);
+
+    testRunner.notifyDone();
+}
+</script>
+<body onload="runTest()">
+<iframe scrolling="no" srcdoc="
+    <html>
+    <style>
+    .scroll-content { width: 500px; height: 5000px; border: 2px solid green; transform:translateZ(0) }
+    </style>
+    <body>
+    <div class='scroll-content'>
+    This document shouldn't be scrollable.
+    </div>
+    </body>
+    </html>
+" width=500 height=500>
+</iframe>
+</body>
+</html>
</ins></span></pre></div>
<a id="branchessafari60812420branchSourceWebKitChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-608.1.24.20-branch/Source/WebKit/ChangeLog (245552 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/Source/WebKit/ChangeLog       2019-05-21 03:21:14 UTC (rev 245552)
+++ branches/safari-608.1.24.20-branch/Source/WebKit/ChangeLog  2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -1,3 +1,58 @@
</span><ins>+2019-05-20  Kocsen Chung  <kocsen_chung@apple.com>
+
+        Cherry-pick r245465. rdar://problem/50252398
+
+    [iOS] Respect scrolling="no" on composited frames
+    https://bugs.webkit.org/show_bug.cgi?id=197972
+    <rdar://problem/50252398>
+    
+    Reviewed by Simon Fraser.
+    
+    Source/WebKit:
+    
+    * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h:
+    * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm:
+    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::commitStateAfterChildren):
+    
+    Disallow scrolling based on canHaveScrollbars, similar to main frame.
+    
+    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::repositionScrollingLayers):
+    (WebKit::ScrollingTreeScrollingNodeDelegateIOS::scrollView const):
+    
+    Factor into a function.
+    
+    LayoutTests:
+    
+    * fast/scrolling/ios/body-overflow-hidden-frame-expected.html:
+    * fast/scrolling/ios/body-overflow-hidden-frame.html:
+    
+    Also fix overflow:hidden test so that the frame content forces composition.
+    
+    * fast/scrolling/ios/frame-scrolling-no-expected.html: Added.
+    * fast/scrolling/ios/frame-scrolling-no.html: Added.
+    
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@245465 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2019-05-17  Antti Koivisto  <antti@apple.com>
+
+            [iOS] Respect scrolling="no" on composited frames
+            https://bugs.webkit.org/show_bug.cgi?id=197972
+            <rdar://problem/50252398>
+
+            Reviewed by Simon Fraser.
+
+            * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h:
+            * UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm:
+            (WebKit::ScrollingTreeScrollingNodeDelegateIOS::commitStateAfterChildren):
+
+            Disallow scrolling based on canHaveScrollbars, similar to main frame.
+
+            (WebKit::ScrollingTreeScrollingNodeDelegateIOS::repositionScrollingLayers):
+            (WebKit::ScrollingTreeScrollingNodeDelegateIOS::scrollView const):
+
+            Factor into a function.
+
</ins><span class="cx"> 2019-05-15  Kocsen Chung  <kocsen_chung@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Cherry-pick r245360. rdar://problem/50823976
</span></span></pre></div>
<a id="branchessafari60812420branchSourceWebKitUIProcessRemoteLayerTreeiosScrollingTreeScrollingNodeDelegateIOSh"></a>
<div class="modfile"><h4>Modified: branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h (245552 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h   2019-05-21 03:21:14 UTC (rev 245552)
+++ branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.h      2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -33,6 +33,7 @@
</span><span class="cx"> #include <WebCore/ScrollingTreeScrollingNodeDelegate.h>
</span><span class="cx"> 
</span><span class="cx"> OBJC_CLASS CALayer;
</span><ins>+OBJC_CLASS UIScrollView;
</ins><span class="cx"> OBJC_CLASS WKScrollingNodeScrollViewDelegate;
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="lines">@@ -71,6 +72,8 @@
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> private:
</span><ins>+    UIScrollView *scrollView() const;
+
</ins><span class="cx">     RetainPtr<CALayer> m_scrollLayer;
</span><span class="cx">     RetainPtr<CALayer> m_scrolledContentsLayer;
</span><span class="cx">     RetainPtr<WKScrollingNodeScrollViewDelegate> m_scrollViewDelegate;
</span></span></pre></div>
<a id="branchessafari60812420branchSourceWebKitUIProcessRemoteLayerTreeiosScrollingTreeScrollingNodeDelegateIOSmm"></a>
<div class="modfile"><h4>Modified: branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm (245552 => 245553)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm  2019-05-21 03:21:14 UTC (rev 245552)
+++ branches/safari-608.1.24.20-branch/Source/WebKit/UIProcess/RemoteLayerTree/ios/ScrollingTreeScrollingNodeDelegateIOS.mm     2019-05-21 03:21:18 UTC (rev 245553)
</span><span class="lines">@@ -230,9 +230,7 @@
</span><span class="cx">         || scrollingStateNode.hasChangedProperty(ScrollingStateScrollingNode::ScrollPosition)
</span><span class="cx">         || scrollingStateNode.hasChangedProperty(ScrollingStateScrollingNode::ScrollOrigin)) {
</span><span class="cx">         BEGIN_BLOCK_OBJC_EXCEPTIONS
</span><del>-        UIScrollView *scrollView = (UIScrollView *)[scrollLayer() delegate];
-        ASSERT([scrollView isKindOfClass:[UIScrollView self]]);
-
</del><ins>+        UIScrollView *scrollView = this->scrollView();
</ins><span class="cx">         if (scrollingStateNode.hasChangedProperty(ScrollingStateScrollingNode::ScrollContainerLayer)) {
</span><span class="cx">             if (!m_scrollViewDelegate)
</span><span class="cx">                 m_scrollViewDelegate = adoptNS([[WKScrollingNodeScrollViewDelegate alloc] initWithScrollingTreeNodeDelegate:this]);
</span><span class="lines">@@ -268,21 +266,18 @@
</span><span class="cx">     // FIXME: If only one axis snaps in 2D scrolling, the other axis will decelerate fast as well. Is this what we want?
</span><span class="cx">     if (scrollingStateNode.hasChangedProperty(ScrollingStateScrollingNode::HorizontalSnapOffsets) || scrollingStateNode.hasChangedProperty(ScrollingStateScrollingNode::VerticalSnapOffsets)) {
</span><span class="cx">         BEGIN_BLOCK_OBJC_EXCEPTIONS
</span><del>-        UIScrollView *scrollView = (UIScrollView *)[scrollLayer() delegate];
-        ASSERT([scrollView isKindOfClass:[UIScrollView self]]);
-
-        scrollView.decelerationRate = scrollingNode().horizontalSnapOffsets().size() || scrollingNode().verticalSnapOffsets().size() ? UIScrollViewDecelerationRateFast : UIScrollViewDecelerationRateNormal;
-#endif
</del><ins>+        scrollView().decelerationRate = scrollingNode().horizontalSnapOffsets().size() || scrollingNode().verticalSnapOffsets().size() ? UIScrollViewDecelerationRateFast : UIScrollViewDecelerationRateNormal;
</ins><span class="cx">         END_BLOCK_OBJC_EXCEPTIONS
</span><span class="cx">     }
</span><ins>+#endif
</ins><span class="cx"> 
</span><span class="cx">     if (scrollingStateNode.hasChangedProperty(ScrollingStateScrollingNode::ScrollableAreaParams)) {
</span><span class="cx">         BEGIN_BLOCK_OBJC_EXCEPTIONS
</span><del>-        UIScrollView *scrollView = (UIScrollView *)[scrollLayer() delegate];
-        ASSERT([scrollView isKindOfClass:[UIScrollView self]]);
</del><ins>+        UIScrollView *scrollView = this->scrollView();
</ins><span class="cx"> 
</span><span class="cx">         [scrollView setShowsHorizontalScrollIndicator:!scrollingNode().horizontalScrollbarHiddenByStyle()];
</span><span class="cx">         [scrollView setShowsVerticalScrollIndicator:!scrollingNode().verticalScrollbarHiddenByStyle()];
</span><ins>+        [scrollView setScrollEnabled:scrollingNode().canHaveScrollbars()];
</ins><span class="cx"> 
</span><span class="cx">         END_BLOCK_OBJC_EXCEPTIONS
</span><span class="cx">     }
</span><span class="lines">@@ -298,9 +293,7 @@
</span><span class="cx">     auto scrollPosition = scrollingNode().currentScrollPosition();
</span><span class="cx"> 
</span><span class="cx">     BEGIN_BLOCK_OBJC_EXCEPTIONS
</span><del>-    UIScrollView *scrollView = (UIScrollView *)[scrollLayer() delegate];
-    ASSERT([scrollView isKindOfClass:[UIScrollView self]]);
-    [scrollView setContentOffset:scrollPosition];
</del><ins>+    [scrollView() setContentOffset:scrollPosition];
</ins><span class="cx">     END_BLOCK_OBJC_EXCEPTIONS
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -335,6 +328,13 @@
</span><span class="cx">     scrollingTree().currentSnapPointIndicesDidChange(scrollingNode().scrollingNodeID(), horizontal, vertical);
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+UIScrollView *ScrollingTreeScrollingNodeDelegateIOS::scrollView() const
+{
+    UIScrollView *scrollView = (UIScrollView *)[scrollLayer() delegate];
+    ASSERT([scrollView isKindOfClass:[UIScrollView self]]);
+    return scrollView;
+}
+
</ins><span class="cx"> #if ENABLE(POINTER_EVENTS)
</span><span class="cx"> OptionSet<TouchAction> ScrollingTreeScrollingNodeDelegateIOS::activeTouchActionsForGestureRecognizer(UIGestureRecognizer* gestureRecognizer) const
</span><span class="cx"> {
</span></span></pre>
</div>
</div>

</body>
</html>