<!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>[184265] branches/safari-601.1.32-branch/Source</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/184265">184265</a></dd>
<dt>Author</dt> <dd>dburkart@apple.com</dd>
<dt>Date</dt> <dd>2015-05-12 22:33:23 -0700 (Tue, 12 May 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>Merge <a href="http://trac.webkit.org/projects/webkit/changeset/184139">r184139</a>. rdar://problem/20125088</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#branchessafari601132branchSourceWebCoreChangeLog">branches/safari-601.1.32-branch/Source/WebCore/ChangeLog</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepageFrameViewcpp">branches/safari-601.1.32-branch/Source/WebCore/page/FrameView.cpp</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingAsyncScrollingCoordinatorcpp">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingAsyncScrollingCoordinatorh">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingAxisScrollSnapOffsetsh">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AxisScrollSnapOffsets.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingScrollingTreeh">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ScrollingTree.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingThreadedScrollingTreecpp">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.cpp</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingThreadedScrollingTreeh">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCorepagescrollingmacScrollingTreeFrameScrollingNodeMacmm">branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformScrollAnimatorcpp">branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.cpp</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformScrollAnimatorh">branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformScrollableAreacpp">branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.cpp</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformScrollableAreah">branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformcocoaScrollControllerh">branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformcocoaScrollControllermm">branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.mm</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformcocoaScrollSnapAnimatorStateh">branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.h</a></li>
<li><a href="#branchessafari601132branchSourceWebCoreplatformcocoaScrollSnapAnimatorStatemm">branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.mm</a></li>
<li><a href="#branchessafari601132branchSourceWebCorerenderingRenderLayercpp">branches/safari-601.1.32-branch/Source/WebCore/rendering/RenderLayer.cpp</a></li>
<li><a href="#branchessafari601132branchSourceWebKit2ChangeLog">branches/safari-601.1.32-branch/Source/WebKit2/ChangeLog</a></li>
<li><a href="#branchessafari601132branchSourceWebKit2UIProcessScrollingiosScrollingTreeOverflowScrollingNodeIOSmm">branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm</a></li>
<li><a href="#branchessafari601132branchSourceWebKit2UIProcessiosRemoteScrollingCoordinatorProxyIOSmm">branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="branchessafari601132branchSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/ChangeLog (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/ChangeLog        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/ChangeLog        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -2,502 +2,579 @@
</span><span class="cx"> Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx"> dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-        Merge r184137. rdar://problem/20707307
</del><ins>+        Merge r184139. rdar://problem/20125088
</ins><span class="cx"> 
</span><span class="cx">     2015-05-11  Brent Fulgham  &lt;bfulgham@apple.com&gt;
</span><span class="cx"> 
</span><del>-            [Win] Move Windows build target to Windows 7 (or newer)
-            https://bugs.webkit.org/show_bug.cgi?id=144890
-            &lt;rdar://problem/20707307&gt;
</del><ins>+            Scroll snap logic should be triggered when resizing the WebView
+            https://bugs.webkit.org/show_bug.cgi?id=142590
+            &lt;rdar://problem/20125088&gt;
</ins><span class="cx"> 
</span><del>-            Reviewed by Anders Carlsson.
</del><ins>+            Reviewed by Simon Fraser.
</ins><span class="cx"> 
</span><del>-            Update linked SDK and minimal Windows level to be compatible with
-            Windows 7 or newer.
</del><ins>+            Tests coming in a second patch.
</ins><span class="cx"> 
</span><del>-            * WebCore.vcxproj/WebCore.vcxproj:
-            * WebCore.vcxproj/WebCoreGenerated.vcxproj:
-            * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
-            * WebCorePrefix.h:
-            * config.h:
-            * testing/js/WebCoreTestSupportPrefix.h:
</del><ins>+            Resizing of the main frame or overflow regions was properly recalculating the scroll snap points,
+            but there was no code to honor these values when window resizing was occurring. The correction was
+            handled in two ways:
+            1. Scrolling thread operations that moved to new snap points needed to notify the main thread that
+               it had shifted to a new snap point, so that the resize code (which happens on the main thread)
+               could ensure that we stayed clamped to the correct 'tile' in the snap region.
+            2. Main thread (overflow) resizes were likewise missing code to honor the current snap position
+               after resizing calculations were complete.
</ins><span class="cx"> 
</span><ins>+            This change also required the addition of two indices to the scrollable area to track which scroll
+            snap point was currently being used. We don't bother with a 'none' case because you cannot have a
+            'none' state when you have an active set of scroll snap points, and we do not execute this code
+            if the scroll snap points are null.
+
+            The FrameView code was computing updated snap offsets after it had dispatched frame view layout
+            information to the scrolling thread, which was wrong. This was also corrected.
+
+            I think it might be possible to track all of this state inside the ScrollController, but the current
+            scroll snap architecture destroys and recreates the state each time a new set of interactions starts.
+            This should be fixed in the future, which would allow us to remove some of this local state.
+
+            * page/FrameView.cpp:
+            (WebCore::FrameView::performPostLayoutTasks): Make sure 'updateSnapOffsets' is called prior to
+            calling 'frameViewLayoutUpdated' so the scrolling thread gets correct updated points. Add a new
+            call to 'scrollToNearestActiveSnapPoint', which will keep us on our current snap point during
+            resize (if appropriate).
+            * page/scrolling/AsyncScrollingCoordinator.cpp:
+            (WebCore::AsyncScrollingCoordinator::updateScrollSnapOffsetIndices): Added. This finds and notifies
+            the correct scroll region when a new snap position (index) has been selected by user interaction on
+            the scrolling thread.
+            (WebCore::AsyncScrollingCoordinator::deferTestsForReason): Added an assertion for 'isMainThread'.
+            (WebCore::AsyncScrollingCoordinator::removeTestDeferralForReason): Ditto.
+            * page/scrolling/AsyncScrollingCoordinator.h:
+            * page/scrolling/AxisScrollSnapOffsets.h:
+            (WebCore::closestSnapOffset): Modified to also return the selected snap point index so we can track
+            it to handle resize operations.
+            * page/scrolling/ScrollingTree.h:
+            (WebCore::ScrollingTree::updateScrollSnapOffsetIndices):
+            * page/scrolling/ThreadedScrollingTree.cpp:
+            (WebCore::ThreadedScrollingTree::updateScrollSnapOffsetIndices): Added method to dispatch the active
+            horizontal and vertical scroll snap indices back to the main thread.
+            * page/scrolling/ThreadedScrollingTree.h:
+            * page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm:
+            (WebCore::ScrollingTreeFrameScrollingNodeMac::handleWheelEvent): After the scroll controller processes
+            the current event, notify the main thread of any change in the active scroll snap index.
+            * platform/ScrollAnimator.cpp:
+            (WebCore::ScrollAnimator::activeScrollSnapOffsetIndexDidChange): Added method to allow ScrollAnimator
+            clients to find out about the current scroll snap state, which is only known by the ScrollController.
+            (WebCore::ScrollAnimator::activeScrollSnapOffsetIndexForAxis): Ditto.
+            * platform/ScrollAnimator.h:
+            * platform/ScrollView.cpp:
+            (WebCore::ScrollView::scrollToNearestActiveSnapPoint): Added method that allows us to set scroll position
+            to one of our active scroll snap offsets.
+            * platform/ScrollView.h:
+            * platform/ScrollableArea.cpp:
+            (WebCore::ScrollableArea::handleWheelEvent): If the active scroll snap offset has changed, make sure we
+            keep track of the new values for potential resize operations.
+            (WebCore::ScrollableArea::clearHorizontalSnapOffsets): Make sure to also clear out the current snap index.
+            (WebCore::ScrollableArea::clearVerticalSnapOffsets): Ditto.
+            (WebCore::ScrollableArea::nearestActiveSnapPoint): New method that returns an updated IntPoint reflecting
+            the proper scroll position based on the active scroll snap offset.
+            * platform/ScrollableArea.h:
+            (WebCore::ScrollableArea::currentHorizontalSnapPointIndex): Added.
+            (WebCore::ScrollableArea::setCurrentHorizontalSnapPointIndex): Added.
+            (WebCore::ScrollableArea::currentVerticalSnapPointIndex): Added.
+            (WebCore::ScrollableArea::setCurrentVerticalSnapPointIndex): Added.
+            (WebCore::ScrollableArea::scrollToNearestActiveSnapPoint): Added.
+            * platform/cocoa/ScrollController.h:
+            (WebCore::ScrollControllerClient::activeScrollOffsetIndex): Added new method for clients to implement.
+            (WebCore::ScrollController::activeScrollSnapOffsetIndexDidChange): Added.
+            (WebCore::ScrollController::setScrollSnapOffsetIndexDidChange): Added.
+            * platform/cocoa/ScrollController.mm:
+            (WebCore::ScrollController::activeScrollSnapOffsetIndexForAxis): Helper method to return current active
+            index (if applicable).
+            (WebCore::ScrollController::setActiveScrollSnapOffsetIndexForAxis): Helper function to safely set
+            the current active index.
+            (WebCore::ScrollController::beginScrollSnapAnimation): Updated to keep track of the new active scroll snap
+            index, as well as whether the current animation actually changed the active snap point offset.
+            * platform/cocoa/ScrollSnapAnimatorState.h: Revise to use modern C++ initializers, and to track a new index
+            that represents the current scroll snap offset.
+            * platform/cocoa/ScrollSnapAnimatorState.mm:
+            (WebCore::ScrollSnapAnimatorState::ScrollSnapAnimatorState): Update for modern C++ syntax.
+            * rendering/RenderLayer.cpp:
+            (WebCore::RenderLayer::scrollToNearestActiveSnapPoint): New method to set scroll position to be one of our
+            active scroll snap points.
+            (WebCore::RenderLayer::updateScrollInfoAfterLayout): Add a new call to 'scrollToNearestActiveSnapPoint' so that
+            we stay on the current scroll snap offset during resizing.
+            * rendering/RenderLayer.h:
+
</ins><span class="cx">     2015-05-12  Dana Burkart
</span><span class="cx">     Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">     dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-            Merge r184116. rdar://problem/20774613
</del><ins>+            Merge r184137. rdar://problem/20707307
</ins><span class="cx"> 
</span><del>-        2015-05-11  Alex Christensen  &lt;achristensen@webkit.org&gt;
</del><ins>+        2015-05-11  Brent Fulgham  &lt;bfulgham@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                [Content Extensions] Support domain-specific rules and exceptions.
-                https://bugs.webkit.org/show_bug.cgi?id=144833
</del><ins>+                [Win] Move Windows build target to Windows 7 (or newer)
+                https://bugs.webkit.org/show_bug.cgi?id=144890
+                &lt;rdar://problem/20707307&gt;
</ins><span class="cx"> 
</span><del>-                Reviewed by Darin Adler.
</del><ins>+                Reviewed by Anders Carlsson.
</ins><span class="cx"> 
</span><del>-                Test: http/tests/contentextensions/domain-rules.html
-                (And lots of API tests)
</del><ins>+                Update linked SDK and minimal Windows level to be compatible with
+                Windows 7 or newer.
</ins><span class="cx"> 
</span><del>-                This patch adds if-domain and unless-domain to the trigger in the JSON format.
-                if-domain makes the rule apply only to domains in the list.
-                unless-domain makes the rule apply to domains that are not in the list.
</del><ins>+                * WebCore.vcxproj/WebCore.vcxproj:
+                * WebCore.vcxproj/WebCoreGenerated.vcxproj:
+                * WebCore.vcxproj/WebCoreTestSupport.vcxproj:
+                * WebCorePrefix.h:
+                * config.h:
+                * testing/js/WebCoreTestSupportPrefix.h:
</ins><span class="cx"> 
</span><del>-                All rules without if-domain or unless-domain are compiled into a set of DFAs.  This behavior is unchanged.
-                All rules with if-domain or unless-domain are compiled into a separate set of DFAs.
-                The domains are also compiled into another set of DFAs.  This makes 3 arrays of DFA bytecode instead of 1.
-
-                If there are no domain specific rules, there is no change in behavior.
-                If there are domain specific rules, the URL will be checked for matches in both
-                filtersWithoutDomainsBytecode and filtersWithDomainsBytecode.  If there are matches from
-                filtersWithDomainsBytecode then the domain of the main document will be checked with
-                domainFiltersBytecode to see which of the matches applies to this domain.
-
-                * contentextensions/CombinedURLFilters.cpp:
-                (WebCore::ContentExtensions::CombinedURLFilters::isEmpty):
-                (WebCore::ContentExtensions::CombinedURLFilters::addDomain):
-                * contentextensions/CombinedURLFilters.h:
-                Added addDomain, which adds characters from a domain to the prefix tree directly without using YARR.
-                * contentextensions/CompiledContentExtension.cpp:
-                (WebCore::ContentExtensions::CompiledContentExtension::globalDisplayNoneSelectors):
-                * contentextensions/CompiledContentExtension.h:
-                * contentextensions/ContentExtensionCompiler.cpp:
-                (WebCore::ContentExtensions::serializeActions):
-                (WebCore::ContentExtensions::compileRuleList):
-                Separate the rules into rules with domains and rules without domains and compile to bytecode.
-                * contentextensions/ContentExtensionCompiler.h:
-                Updated compiler interface to reflect the slightly more complicated structure.
-                * contentextensions/ContentExtensionError.cpp:
-                (WebCore::ContentExtensions::contentExtensionErrorCategory):
-                * contentextensions/ContentExtensionError.h:
-                Added new parsing errors.
-                * contentextensions/ContentExtensionParser.cpp:
-                (WebCore::ContentExtensions::getDomainList):
-                (WebCore::ContentExtensions::loadTrigger):
-                (WebCore::ContentExtensions::loadEncodedRules):
-                * contentextensions/ContentExtensionRule.h:
-                (WebCore::ContentExtensions::Trigger::operator==):
-                Parse the new domain structures from JSON into the Trigger structure.
-                * contentextensions/ContentExtensionsBackend.cpp:
-                (WebCore::ContentExtensions::ContentExtensionsBackend::actionsForResourceLoad):
-                Interpret as much bytecode as necessary to determine which rules apply to this URL and domain.
-                * contentextensions/DFABytecode.h:
-                (WebCore::ContentExtensions::instructionSizeWithArguments):
-                * contentextensions/DFABytecodeCompiler.cpp:
-                (WebCore::ContentExtensions::DFABytecodeCompiler::emitAppendAction):
-                (WebCore::ContentExtensions::DFABytecodeCompiler::emitTestFlagsAndAppendAction):
-                (WebCore::ContentExtensions::DFABytecodeCompiler::compileNode):
-                * contentextensions/DFABytecodeCompiler.h:
-                * contentextensions/DFABytecodeInterpreter.cpp:
-                (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretAppendAction):
-                (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretTestFlagsAndAppendAction):
-                (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsFromDFARoot):
-                (WebCore::ContentExtensions::DFABytecodeInterpreter::interpret):
-                * contentextensions/DFABytecodeInterpreter.h:
-                * loader/ResourceLoadInfo.h:
-                Keep track of which actions have an if-domain trigger.  If an action is in the
-                filtersWithDomainsBytecode, then it either has an if-domain or an unless-domain in its trigger.
-                This requires additional information in the bytecode, so there are two new bytecode types.
-
</del><span class="cx">         2015-05-12  Dana Burkart
</span><span class="cx">         Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">         dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                Merge r184104. rdar://problem/20727702
</del><ins>+                Merge r184116. rdar://problem/20774613
</ins><span class="cx"> 
</span><del>-            2015-05-11  Antti Koivisto  &lt;antti@apple.com&gt;
</del><ins>+            2015-05-11  Alex Christensen  &lt;achristensen@webkit.org&gt;
</ins><span class="cx"> 
</span><del>-                    WebContent crash under com.apple.WebCore: WebCore::WebKitCSSResourceValue::isCSSValueNone const + 6
-                    https://bugs.webkit.org/show_bug.cgi?id=144870
-                    rdar://problem/20727702
</del><ins>+                    [Content Extensions] Support domain-specific rules and exceptions.
+                    https://bugs.webkit.org/show_bug.cgi?id=144833
</ins><span class="cx"> 
</span><del>-                    Reviewed by Simon Fraser.
</del><ins>+                    Reviewed by Darin Adler.
</ins><span class="cx"> 
</span><del>-                    No repro but we are seeing null pointer crashes like this:
</del><ins>+                    Test: http/tests/contentextensions/domain-rules.html
+                    (And lots of API tests)
</ins><span class="cx"> 
</span><del>-                    Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
-                    0   com.apple.WebCore   0x00007fff92da5706 WebCore::WebKitCSSResourceValue::isCSSValueNone() const + 6
-                    1   com.apple.WebCore   0x00007fff93382b48 WebCore::MaskImageOperation::isCSSValueNone() const + 24
-                    2   com.apple.WebCore   0x00007fff92e0475e WebCore::FillLayer::hasNonEmptyMaskImage() const + 30
</del><ins>+                    This patch adds if-domain and unless-domain to the trigger in the JSON format.
+                    if-domain makes the rule apply only to domains in the list.
+                    unless-domain makes the rule apply to domains that are not in the list.
</ins><span class="cx"> 
</span><del>-                    * platform/graphics/MaskImageOperation.cpp:
-                    (WebCore::MaskImageOperation::MaskImageOperation):
-                    (WebCore::MaskImageOperation::isCSSValueNone):
</del><ins>+                    All rules without if-domain or unless-domain are compiled into a set of DFAs.  This behavior is unchanged.
+                    All rules with if-domain or unless-domain are compiled into a separate set of DFAs.
+                    The domains are also compiled into another set of DFAs.  This makes 3 arrays of DFA bytecode instead of 1.
</ins><span class="cx"> 
</span><del>-                        This would crash like this if both m_styleImage and m_cssMaskImageValue are null.
-                        There are no obvious guarantees that this doesn't happen. Two of the constructor variants allow it
-                        and there is setImage which may turn m_styleImage null later too.
</del><ins>+                    If there are no domain specific rules, there is no change in behavior.
+                    If there are domain specific rules, the URL will be checked for matches in both
+                    filtersWithoutDomainsBytecode and filtersWithDomainsBytecode.  If there are matches from
+                    filtersWithDomainsBytecode then the domain of the main document will be checked with
+                    domainFiltersBytecode to see which of the matches applies to this domain.
</ins><span class="cx"> 
</span><del>-                        Fix by making null m_cssMaskImageValue always signify CSSValueNone.
</del><ins>+                    * contentextensions/CombinedURLFilters.cpp:
+                    (WebCore::ContentExtensions::CombinedURLFilters::isEmpty):
+                    (WebCore::ContentExtensions::CombinedURLFilters::addDomain):
+                    * contentextensions/CombinedURLFilters.h:
+                    Added addDomain, which adds characters from a domain to the prefix tree directly without using YARR.
+                    * contentextensions/CompiledContentExtension.cpp:
+                    (WebCore::ContentExtensions::CompiledContentExtension::globalDisplayNoneSelectors):
+                    * contentextensions/CompiledContentExtension.h:
+                    * contentextensions/ContentExtensionCompiler.cpp:
+                    (WebCore::ContentExtensions::serializeActions):
+                    (WebCore::ContentExtensions::compileRuleList):
+                    Separate the rules into rules with domains and rules without domains and compile to bytecode.
+                    * contentextensions/ContentExtensionCompiler.h:
+                    Updated compiler interface to reflect the slightly more complicated structure.
+                    * contentextensions/ContentExtensionError.cpp:
+                    (WebCore::ContentExtensions::contentExtensionErrorCategory):
+                    * contentextensions/ContentExtensionError.h:
+                    Added new parsing errors.
+                    * contentextensions/ContentExtensionParser.cpp:
+                    (WebCore::ContentExtensions::getDomainList):
+                    (WebCore::ContentExtensions::loadTrigger):
+                    (WebCore::ContentExtensions::loadEncodedRules):
+                    * contentextensions/ContentExtensionRule.h:
+                    (WebCore::ContentExtensions::Trigger::operator==):
+                    Parse the new domain structures from JSON into the Trigger structure.
+                    * contentextensions/ContentExtensionsBackend.cpp:
+                    (WebCore::ContentExtensions::ContentExtensionsBackend::actionsForResourceLoad):
+                    Interpret as much bytecode as necessary to determine which rules apply to this URL and domain.
+                    * contentextensions/DFABytecode.h:
+                    (WebCore::ContentExtensions::instructionSizeWithArguments):
+                    * contentextensions/DFABytecodeCompiler.cpp:
+                    (WebCore::ContentExtensions::DFABytecodeCompiler::emitAppendAction):
+                    (WebCore::ContentExtensions::DFABytecodeCompiler::emitTestFlagsAndAppendAction):
+                    (WebCore::ContentExtensions::DFABytecodeCompiler::compileNode):
+                    * contentextensions/DFABytecodeCompiler.h:
+                    * contentextensions/DFABytecodeInterpreter.cpp:
+                    (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretAppendAction):
+                    (WebCore::ContentExtensions::DFABytecodeInterpreter::interpretTestFlagsAndAppendAction):
+                    (WebCore::ContentExtensions::DFABytecodeInterpreter::actionsFromDFARoot):
+                    (WebCore::ContentExtensions::DFABytecodeInterpreter::interpret):
+                    * contentextensions/DFABytecodeInterpreter.h:
+                    * loader/ResourceLoadInfo.h:
+                    Keep track of which actions have an if-domain trigger.  If an action is in the
+                    filtersWithDomainsBytecode, then it either has an if-domain or an unless-domain in its trigger.
+                    This requires additional information in the bytecode, so there are two new bytecode types.
</ins><span class="cx"> 
</span><del>-                    (WebCore::MaskImageOperation::cssValue):
-
</del><span class="cx">             2015-05-12  Dana Burkart
</span><span class="cx">             Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">             dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                    Merge r184005. rdar://problem/20486538
</del><ins>+                    Merge r184104. rdar://problem/20727702
</ins><span class="cx"> 
</span><del>-                2015-05-08  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</del><ins>+                2015-05-11  Antti Koivisto  &lt;antti@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                        Crashes in SocketStreamHandleBase::close
-                        https://bugs.webkit.org/show_bug.cgi?id=144767
-                        rdar://problem/20486538
</del><ins>+                        WebContent crash under com.apple.WebCore: WebCore::WebKitCSSResourceValue::isCSSValueNone const + 6
+                        https://bugs.webkit.org/show_bug.cgi?id=144870
+                        rdar://problem/20727702
</ins><span class="cx"> 
</span><del>-                        Reviewed by Brady Eidson.
</del><ins>+                        Reviewed by Simon Fraser.
</ins><span class="cx"> 
</span><del>-                        This is a speculative fix, I could not reproduce the crash.
</del><ins>+                        No repro but we are seeing null pointer crashes like this:
</ins><span class="cx"> 
</span><del>-                        * Modules/websockets/WebSocketChannel.cpp: (WebCore::WebSocketChannel::processFrame):
-                        Normally, processOutgoingFrameQueue() closes the handle in the end when called in
-                        OutgoingFrameQueueClosing state. But there is no definitive protection against
-                        processing two CLOSE frames, in which case we'd try to close the handle twice.
</del><ins>+                        Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
+                        0   com.apple.WebCore   0x00007fff92da5706 WebCore::WebKitCSSResourceValue::isCSSValueNone() const + 6
+                        1   com.apple.WebCore   0x00007fff93382b48 WebCore::MaskImageOperation::isCSSValueNone() const + 24
+                        2   com.apple.WebCore   0x00007fff92e0475e WebCore::FillLayer::hasNonEmptyMaskImage() const + 30
</ins><span class="cx"> 
</span><del>-                        * platform/network/cf/SocketStreamHandleCFNet.cpp:
-                        (WebCore::SocketStreamHandle::readStreamCallback): Passing empty data to the client
-                        results in the socket being closed, which makes no sense here.
</del><ins>+                        * platform/graphics/MaskImageOperation.cpp:
+                        (WebCore::MaskImageOperation::MaskImageOperation):
+                        (WebCore::MaskImageOperation::isCSSValueNone):
</ins><span class="cx"> 
</span><ins>+                            This would crash like this if both m_styleImage and m_cssMaskImageValue are null.
+                            There are no obvious guarantees that this doesn't happen. Two of the constructor variants allow it
+                            and there is setImage which may turn m_styleImage null later too.
+
+                            Fix by making null m_cssMaskImageValue always signify CSSValueNone.
+
+                        (WebCore::MaskImageOperation::cssValue):
+
</ins><span class="cx">                 2015-05-12  Dana Burkart
</span><span class="cx">                 Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                 dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                        Merge r184001. rdar://problem/20862460
</del><ins>+                        Merge r184005. rdar://problem/20486538
</ins><span class="cx"> 
</span><del>-                    2015-05-08  Eric Carlson  &lt;eric.carlson@apple.com&gt;
</del><ins>+                    2015-05-08  Alexey Proskuryakov  &lt;ap@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                            [Mac] Playback target clients do not unregister on page reload
-                            https://bugs.webkit.org/show_bug.cgi?id=144761
</del><ins>+                            Crashes in SocketStreamHandleBase::close
+                            https://bugs.webkit.org/show_bug.cgi?id=144767
+                            rdar://problem/20486538
</ins><span class="cx"> 
</span><span class="cx">                             Reviewed by Brady Eidson.
</span><span class="cx"> 
</span><del>-                            * dom/Document.cpp:
-                            (WebCore::Document::prepareForDestruction): Unregister all target picker clients.
</del><ins>+                            This is a speculative fix, I could not reproduce the crash.
</ins><span class="cx"> 
</span><del>-                            * html/HTMLMediaElement.cpp:
-                            (WebCore::HTMLMediaElement::registerWithDocument): Register for page cache callback.
-                            (WebCore::HTMLMediaElement::unregisterWithDocument): Unregister for page cache callback.
-                            (WebCore::HTMLMediaElement::documentWillSuspendForPageCache): New.
-                            (WebCore::HTMLMediaElement::documentDidResumeFromPageCache): New.
</del><ins>+                            * Modules/websockets/WebSocketChannel.cpp: (WebCore::WebSocketChannel::processFrame):
+                            Normally, processOutgoingFrameQueue() closes the handle in the end when called in
+                            OutgoingFrameQueueClosing state. But there is no definitive protection against
+                            processing two CLOSE frames, in which case we'd try to close the handle twice.
</ins><span class="cx"> 
</span><ins>+                            * platform/network/cf/SocketStreamHandleCFNet.cpp:
+                            (WebCore::SocketStreamHandle::readStreamCallback): Passing empty data to the client
+                            results in the socket being closed, which makes no sense here.
+
</ins><span class="cx">                     2015-05-12  Dana Burkart
</span><span class="cx">                     Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                     dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                            Merge r183971. rdar://problem/20065572
</del><ins>+                            Merge r184001. rdar://problem/20862460
</ins><span class="cx"> 
</span><del>-                        2015-05-07  Dean Jackson  &lt;dino@apple.com&gt;
</del><ins>+                        2015-05-08  Eric Carlson  &lt;eric.carlson@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                [iOS] MediaControls: disappear while scrubbing
-                                https://bugs.webkit.org/show_bug.cgi?id=144777
-                                &lt;rdar://problem/20065572&gt;
</del><ins>+                                [Mac] Playback target clients do not unregister on page reload
+                                https://bugs.webkit.org/show_bug.cgi?id=144761
</ins><span class="cx"> 
</span><del>-                                Reviewed by Eric Carlson.
</del><ins>+                                Reviewed by Brady Eidson.
</ins><span class="cx"> 
</span><del>-                                If we are scrubbing we shouldn't hide the controls.
</del><ins>+                                * dom/Document.cpp:
+                                (WebCore::Document::prepareForDestruction): Unregister all target picker clients.
</ins><span class="cx"> 
</span><del>-                                * Modules/mediacontrols/mediaControlsApple.js:
-                                (Controller.prototype.hideControls): Return early if we are scrubbing.
-                                * Modules/mediacontrols/mediaControlsiOS.js:
-                                (ControllerIOS.prototype): Add initial value for _potentiallyScrubbing and
-                                rename from non-underscored value throughout the file.
-                                (ControllerIOS.prototype.handleTimelineTouchEnd): When we finish scrubbing, reset
-                                the timer to hide the controls.
</del><ins>+                                * html/HTMLMediaElement.cpp:
+                                (WebCore::HTMLMediaElement::registerWithDocument): Register for page cache callback.
+                                (WebCore::HTMLMediaElement::unregisterWithDocument): Unregister for page cache callback.
+                                (WebCore::HTMLMediaElement::documentWillSuspendForPageCache): New.
+                                (WebCore::HTMLMediaElement::documentDidResumeFromPageCache): New.
</ins><span class="cx"> 
</span><span class="cx">                         2015-05-12  Dana Burkart
</span><span class="cx">                         Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                         dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                Merge r183970. rdar://problem/20769741
</del><ins>+                                Merge r183971. rdar://problem/20065572
</ins><span class="cx"> 
</span><del>-                            2015-05-07  Simon Fraser  &lt;simon.fraser@apple.com&gt;
</del><ins>+                            2015-05-07  Dean Jackson  &lt;dino@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                    REGRESSION (r183300): Fixed elements flash when scrolling
-                                    https://bugs.webkit.org/show_bug.cgi?id=144778
-                                    rdar://problem/20769741
</del><ins>+                                    [iOS] MediaControls: disappear while scrubbing
+                                    https://bugs.webkit.org/show_bug.cgi?id=144777
+                                    &lt;rdar://problem/20065572&gt;
</ins><span class="cx"> 
</span><del>-                                    Reviewed by Dean Jackson.
</del><ins>+                                    Reviewed by Eric Carlson.
</ins><span class="cx"> 
</span><del>-                                    After r183300 we can detached layer backing store when outside the coverage region.
-                                    However, position:fixed layers are moved around by the ScrollingCoordinator behind
-                                    GraphicsLayer's back, so we can do layer flushes with stale information about layer
-                                    geometry.
</del><ins>+                                    If we are scrubbing we shouldn't hide the controls.
</ins><span class="cx"> 
</span><del>-                                    To avoid dropping backing store for layers in this situation, prevent backing
-                                    store detachment on layers registered with the ScrollingCoordinator as viewport-constrained
-                                    layers. Preventing detachment on a layer also prevents detachment on all descendant
-                                    layers.
</del><ins>+                                    * Modules/mediacontrols/mediaControlsApple.js:
+                                    (Controller.prototype.hideControls): Return early if we are scrubbing.
+                                    * Modules/mediacontrols/mediaControlsiOS.js:
+                                    (ControllerIOS.prototype): Add initial value for _potentiallyScrubbing and
+                                    rename from non-underscored value throughout the file.
+                                    (ControllerIOS.prototype.handleTimelineTouchEnd): When we finish scrubbing, reset
+                                    the timer to hide the controls.
</ins><span class="cx"> 
</span><del>-                                    * platform/graphics/GraphicsLayer.h:
-                                    (WebCore::GraphicsLayer::setAllowsBackingStoreDetachment):
-                                    (WebCore::GraphicsLayer::allowsBackingStoreDetachment):
-                                    * platform/graphics/ca/GraphicsLayerCA.cpp:
-                                    (WebCore::GraphicsLayerCA::GraphicsLayerCA):
-                                    (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects): Set m_intersectsCoverageRect to true
-                                    if backing store detachment is prevented.
-                                    (WebCore::GraphicsLayerCA::recursiveCommitChanges): Set a bit in the CommitState to
-                                    communicate to descendants that detachment is prevented.
-                                    * platform/graphics/ca/GraphicsLayerCA.h:
-                                    (WebCore::GraphicsLayerCA::CommitState::CommitState): Deleted.
-                                    * rendering/RenderLayerBacking.cpp:
-                                    (WebCore::RenderLayerBacking::setIsScrollCoordinatedWithViewportConstrainedRole):
-                                    * rendering/RenderLayerBacking.h:
-                                    (WebCore::RenderLayerBacking::setScrollingNodeIDForRole): If registering with a non-zero
-                                    nodeID for the ViewportConstrained role, turn off backing store detachment.
-
</del><span class="cx">                             2015-05-12  Dana Burkart
</span><span class="cx">                             Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                             dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                    Merge r183965. rdar://problem/20866590
</del><ins>+                                    Merge r183970. rdar://problem/20769741
</ins><span class="cx"> 
</span><del>-                                2015-05-07  Dean Jackson  &lt;dino@apple.com&gt;
</del><ins>+                                2015-05-07  Simon Fraser  &lt;simon.fraser@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                        [iOS] While scrubbing and holding down, video continues to play
-                                        https://bugs.webkit.org/show_bug.cgi?id=144776
-                                        &lt;rdar://problem/20863757&gt;
</del><ins>+                                        REGRESSION (r183300): Fixed elements flash when scrolling
+                                        https://bugs.webkit.org/show_bug.cgi?id=144778
+                                        rdar://problem/20769741
</ins><span class="cx"> 
</span><del>-                                        Reviewed by Simon Fraser.
</del><ins>+                                        Reviewed by Dean Jackson.
</ins><span class="cx"> 
</span><del>-                                        When we are scrubbing a video, we should pause playback. As we
-                                        let go of the scrubber playback can resume (but only if it was
-                                        playing originally).
</del><ins>+                                        After r183300 we can detached layer backing store when outside the coverage region.
+                                        However, position:fixed layers are moved around by the ScrollingCoordinator behind
+                                        GraphicsLayer's back, so we can do layer flushes with stale information about layer
+                                        geometry.
</ins><span class="cx"> 
</span><del>-                                        * Modules/mediacontrols/mediaControlsiOS.js:
-                                        (ControllerIOS.prototype.createControls): Listen for touchstart on the scrubber.
-                                        (ControllerIOS.prototype.handleTimelineInput): Call the prototype, but pause if necessary.
-                                        (ControllerIOS.prototype.handleTimelineChange): Just moved this to be with the other timeline functions.
-                                        (ControllerIOS.prototype.handleTimelineTouchStart): Add the listeners for end and cancel. Remember that we are
-                                        potentially about to scrub.
-                                        (ControllerIOS.prototype.handleTimelineTouchEnd): Remove the listeners.
</del><ins>+                                        To avoid dropping backing store for layers in this situation, prevent backing
+                                        store detachment on layers registered with the ScrollingCoordinator as viewport-constrained
+                                        layers. Preventing detachment on a layer also prevents detachment on all descendant
+                                        layers.
</ins><span class="cx"> 
</span><ins>+                                        * platform/graphics/GraphicsLayer.h:
+                                        (WebCore::GraphicsLayer::setAllowsBackingStoreDetachment):
+                                        (WebCore::GraphicsLayer::allowsBackingStoreDetachment):
+                                        * platform/graphics/ca/GraphicsLayerCA.cpp:
+                                        (WebCore::GraphicsLayerCA::GraphicsLayerCA):
+                                        (WebCore::GraphicsLayerCA::setVisibleAndCoverageRects): Set m_intersectsCoverageRect to true
+                                        if backing store detachment is prevented.
+                                        (WebCore::GraphicsLayerCA::recursiveCommitChanges): Set a bit in the CommitState to
+                                        communicate to descendants that detachment is prevented.
+                                        * platform/graphics/ca/GraphicsLayerCA.h:
+                                        (WebCore::GraphicsLayerCA::CommitState::CommitState): Deleted.
+                                        * rendering/RenderLayerBacking.cpp:
+                                        (WebCore::RenderLayerBacking::setIsScrollCoordinatedWithViewportConstrainedRole):
+                                        * rendering/RenderLayerBacking.h:
+                                        (WebCore::RenderLayerBacking::setScrollingNodeIDForRole): If registering with a non-zero
+                                        nodeID for the ViewportConstrained role, turn off backing store detachment.
+
</ins><span class="cx">                                 2015-05-12  Dana Burkart
</span><span class="cx">                                 Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                                 dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                        Merge r183954. rdar://problem/20281886
</del><ins>+                                        Merge r183965. rdar://problem/20866590
</ins><span class="cx"> 
</span><del>-                                    2015-05-07  Beth Dakin  &lt;bdakin@apple.com&gt;
</del><ins>+                                    2015-05-07  Dean Jackson  &lt;dino@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                            New force-related DOM events should fire in WK1 views
-                                            https://bugs.webkit.org/show_bug.cgi?id=144663
-                                            -and corresponding-
-                                            rdar://problem/20281886
</del><ins>+                                            [iOS] While scrubbing and holding down, video continues to play
+                                            https://bugs.webkit.org/show_bug.cgi?id=144776
+                                            &lt;rdar://problem/20863757&gt;
</ins><span class="cx"> 
</span><del>-                                            Reviewed by Sam Weinig.
</del><ins>+                                            Reviewed by Simon Fraser.
</ins><span class="cx"> 
</span><del>-                                            All of the WK1 mouse events need to take the correspondingPressureEvent.
-                                            * page/EventHandler.h:
</del><ins>+                                            When we are scrubbing a video, we should pause playback. As we
+                                            let go of the scrubber playback can resume (but only if it was
+                                            playing originally).
</ins><span class="cx"> 
</span><del>-                                            Make correspondingPressureEvent a part of CurrentEventScope. This is needed to
-                                            have accurate pressure information for all of the mouse events in subframes.
-                                            * page/mac/EventHandlerMac.mm:
-                                            (WebCore::correspondingPressureEventSlot):
-                                            (WebCore::EventHandler::correspondingPressureEvent):
-                                            (WebCore::CurrentEventScope::CurrentEventScope):
-                                            (WebCore::CurrentEventScope::~CurrentEventScope):
</del><ins>+                                            * Modules/mediacontrols/mediaControlsiOS.js:
+                                            (ControllerIOS.prototype.createControls): Listen for touchstart on the scrubber.
+                                            (ControllerIOS.prototype.handleTimelineInput): Call the prototype, but pause if necessary.
+                                            (ControllerIOS.prototype.handleTimelineChange): Just moved this to be with the other timeline functions.
+                                            (ControllerIOS.prototype.handleTimelineTouchStart): Add the listeners for end and cancel. Remember that we are
+                                            potentially about to scrub.
+                                            (ControllerIOS.prototype.handleTimelineTouchEnd): Remove the listeners.
</ins><span class="cx"> 
</span><del>-                                            These events don’t have an associated pressure, so send nil for the
-                                            correspondingPressureEvent.
-                                            (WebCore::EventHandler::wheelEvent):
-                                            (WebCore::EventHandler::keyEvent):
</del><ins>+                                    2015-05-12  Dana Burkart
+                                    Dana Burkart  &lt;dburkart@apple.com
+                                    dburkart@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                            Pipe through correspondingPressureEvent.
-                                            (WebCore::EventHandler::mouseDown):
-                                            (WebCore::EventHandler::mouseDragged):
-                                            (WebCore::EventHandler::mouseUp):
-                                            (WebCore::EventHandler::mouseMoved):
</del><ins>+                                            Merge r183954. rdar://problem/20281886
</ins><span class="cx"> 
</span><del>-                                            New function to handle pressure change events.
-                                            (WebCore::EventHandler::pressureChange):
</del><ins>+                                        2015-05-07  Beth Dakin  &lt;bdakin@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                            Pipe through correspondingPressureEvent.
-                                            (WebCore::EventHandler::passMouseMovedEventToScrollbars):
-                                            (WebCore::EventHandler::currentPlatformMouseEvent):
</del><ins>+                                                New force-related DOM events should fire in WK1 views
+                                                https://bugs.webkit.org/show_bug.cgi?id=144663
+                                                -and corresponding-
+                                                rdar://problem/20281886
</ins><span class="cx"> 
</span><del>-                                            Take the correspondingPressureEvent in order to build a PlatformMouseEvent with
-                                            the correct pressure information.
-                                            * platform/mac/PlatformEventFactoryMac.h:
-                                            * platform/mac/PlatformEventFactoryMac.mm:
-                                            (WebCore::globalPointForEvent):
-                                            (WebCore::pointForEvent):
-                                            (WebCore::mouseButtonForEvent):
-                                            (WebCore::PlatformMouseEventBuilder::PlatformMouseEventBuilder):
-                                            (WebCore::PlatformEventFactory::createPlatformMouseEvent):
</del><ins>+                                                Reviewed by Sam Weinig.
</ins><span class="cx"> 
</span><del>-                                    2015-05-12  Dana Burkart
-                                    Dana Burkart  &lt;dburkart@apple.com
-                                    dburkart@apple.com&gt;
</del><ins>+                                                All of the WK1 mouse events need to take the correspondingPressureEvent.
+                                                * page/EventHandler.h:
</ins><span class="cx"> 
</span><del>-                                            Merge r183953. rdar://problem/19997548
</del><ins>+                                                Make correspondingPressureEvent a part of CurrentEventScope. This is needed to
+                                                have accurate pressure information for all of the mouse events in subframes.
+                                                * page/mac/EventHandlerMac.mm:
+                                                (WebCore::correspondingPressureEventSlot):
+                                                (WebCore::EventHandler::correspondingPressureEvent):
+                                                (WebCore::CurrentEventScope::CurrentEventScope):
+                                                (WebCore::CurrentEventScope::~CurrentEventScope):
</ins><span class="cx"> 
</span><del>-                                        2015-05-06  Roger Fong  &lt;roger_fong@apple.com&gt;
</del><ins>+                                                These events don’t have an associated pressure, so send nil for the
+                                                correspondingPressureEvent.
+                                                (WebCore::EventHandler::wheelEvent):
+                                                (WebCore::EventHandler::keyEvent):
</ins><span class="cx"> 
</span><del>-                                                Media Controls: Scrubber should be independent of actual video time, causes scrubber to be jumpy.
-                                                https://bugs.webkit.org/show_bug.cgi?id=144700.
-                                                &lt;rdar://problem/19997548&gt;
</del><ins>+                                                Pipe through correspondingPressureEvent.
+                                                (WebCore::EventHandler::mouseDown):
+                                                (WebCore::EventHandler::mouseDragged):
+                                                (WebCore::EventHandler::mouseUp):
+                                                (WebCore::EventHandler::mouseMoved):
</ins><span class="cx"> 
</span><del>-                                                Reviewed by Jer Noble.
</del><ins>+                                                New function to handle pressure change events.
+                                                (WebCore::EventHandler::pressureChange):
</ins><span class="cx"> 
</span><del>-                                                Update time and timeline during the timeline input event instead of the wrapper's mousemove.
-                                                (Controller.prototype.handleWrapperMouseMove):
-                                                (Controller.prototype.handleTimelineMouseMove):
-                                                (Controller.prototype.drawTimelineBackground):
</del><ins>+                                                Pipe through correspondingPressureEvent.
+                                                (WebCore::EventHandler::passMouseMovedEventToScrollbars):
+                                                (WebCore::EventHandler::currentPlatformMouseEvent):
</ins><span class="cx"> 
</span><del>-                                                (Controller.prototype.updateControlsWhileScrubbing):
-                                                Updates time and scrubber to reflect timeline user input.
</del><ins>+                                                Take the correspondingPressureEvent in order to build a PlatformMouseEvent with
+                                                the correct pressure information.
+                                                * platform/mac/PlatformEventFactoryMac.h:
+                                                * platform/mac/PlatformEventFactoryMac.mm:
+                                                (WebCore::globalPointForEvent):
+                                                (WebCore::pointForEvent):
+                                                (WebCore::mouseButtonForEvent):
+                                                (WebCore::PlatformMouseEventBuilder::PlatformMouseEventBuilder):
+                                                (WebCore::PlatformEventFactory::createPlatformMouseEvent):
</ins><span class="cx"> 
</span><span class="cx">                                         2015-05-12  Dana Burkart
</span><span class="cx">                                         Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                                         dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                                Merge r183943. rdar://problem/19913748
</del><ins>+                                                Merge r183953. rdar://problem/19997548
</ins><span class="cx"> 
</span><del>-                                            2015-05-07  Simon Fraser  &lt;simon.fraser@apple.com&gt;
</del><ins>+                                            2015-05-06  Roger Fong  &lt;roger_fong@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                                    Remove the WK1-only code path for independently composited iframes
-                                                    https://bugs.webkit.org/show_bug.cgi?id=144722
</del><ins>+                                                    Media Controls: Scrubber should be independent of actual video time, causes scrubber to be jumpy.
+                                                    https://bugs.webkit.org/show_bug.cgi?id=144700.
+                                                    &lt;rdar://problem/19997548&gt;
</ins><span class="cx"> 
</span><del>-                                                    Reviewed by Dean Jackson.
</del><ins>+                                                    Reviewed by Jer Noble.
</ins><span class="cx"> 
</span><del>-                                                    In WebKit1 on Mac, we allowed iframes to be composited independently of their
-                                                    parent document, relying on the fact that the frame's platform view can host
-                                                    a layer-backed view. However, this ran into bugs (rdar://problem/18862298),
-                                                    and triggers the assertion at the end of FrameView::updateLayoutAndStyleIfNeededRecursive(),
-                                                    because the compositing update after a layout can dirty style in notifyIFramesOfCompositingChange().
</del><ins>+                                                    Update time and timeline during the timeline input event instead of the wrapper's mousemove.
+                                                    (Controller.prototype.handleWrapperMouseMove):
+                                                    (Controller.prototype.handleTimelineMouseMove):
+                                                    (Controller.prototype.drawTimelineBackground):
</ins><span class="cx"> 
</span><del>-                                                    Removing the WK1-only code path solves these problems. It also eliminates the need
-                                                    to do compositing-specific frame overlap testing.
</del><ins>+                                                    (Controller.prototype.updateControlsWhileScrubbing):
+                                                    Updates time and scrubber to reflect timeline user input.
</ins><span class="cx"> 
</span><del>-                                                    * page/FrameView.cpp:
-                                                    (WebCore::FrameView::setIsOverlapped): No need to do compositing-related things here.
-                                                    Any iframe that gets composited will participate in the normal compositing overlap
-                                                    testing in its parent frame.
-                                                    (WebCore::FrameView::hasCompositedContentIncludingDescendants): Deleted.
-                                                    (WebCore::FrameView::hasCompositingAncestor): Deleted.
-                                                    * page/FrameView.h:
-                                                    * rendering/RenderLayerCompositor.cpp: Replace ownerElement() checks in this file
-                                                    with an isMainFrameCompositor() for readability. Some 0-&gt;nullptr.
-                                                    (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingFlags):
-                                                    (WebCore::RenderLayerCompositor::chromeClient):
-                                                    (WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers):
-                                                    (WebCore::RenderLayerCompositor::updateCompositingLayers):
-                                                    (WebCore::RenderLayerCompositor::appendDocumentOverlayLayers):
-                                                    (WebCore::RenderLayerCompositor::updateBacking):
-                                                    (WebCore::RenderLayerCompositor::layerTreeAsText):
-                                                    (WebCore::RenderLayerCompositor::frameContentsCompositor):
-                                                    (WebCore::RenderLayerCompositor::setIsInWindow):
-                                                    (WebCore::RenderLayerCompositor::requiresCompositingForScrollableFrame):
-                                                    (WebCore::RenderLayerCompositor::requiresCompositingForFrame): frameRenderer.requiresAcceleratedCompositing()
-                                                    already bails on no content RenderView, so the shouldPropagateCompositingToEnclosingFrame() check does
-                                                    nothing and is removed.
-                                                    (WebCore::RenderLayerCompositor::isAsyncScrollableStickyLayer):
-                                                    (WebCore::RenderLayerCompositor::requiresScrollLayer):
-                                                    (WebCore::RenderLayerCompositor::documentUsesTiledBacking):
-                                                    (WebCore::RenderLayerCompositor::isMainFrameCompositor):
-                                                    (WebCore::RenderLayerCompositor::shouldCompositeOverflowControls):
-                                                    (WebCore::RenderLayerCompositor::requiresOverhangAreasLayer):
-                                                    (WebCore::RenderLayerCompositor::requiresContentShadowLayer):
-                                                    (WebCore::RenderLayerCompositor::updateLayerForTopOverhangArea):
-                                                    (WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
-                                                    (WebCore::RenderLayerCompositor::updateLayerForHeader):
-                                                    (WebCore::RenderLayerCompositor::updateLayerForFooter):
-                                                    (WebCore::RenderLayerCompositor::ensureRootLayer): Main frame attaches via ChromeClient,
-                                                    all other frames attach via parent frame.
-                                                    (WebCore::RenderLayerCompositor::notifyIFramesOfCompositingChange): This call to
-                                                    scheduleSetNeedsStyleRecalc(SyntheticStyleChange) was the source of dirtying style after
-                                                    layout, but is no longer needed so remove it.
-                                                    (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
-                                                    (WebCore::RenderLayerCompositor::unregisterAllViewportConstrainedLayers):
-                                                    (WebCore::RenderLayerCompositor::scrollingCoordinator):
-                                                    (WebCore::RenderLayerCompositor::graphicsLayerFactory):
-                                                    (WebCore::RenderLayerCompositor::allowsIndependentlyCompositedFrames): Deleted.
-                                                    (WebCore::RenderLayerCompositor::shouldPropagateCompositingToEnclosingFrame): Deleted.
-                                                    (WebCore::RenderLayerCompositor::mainFrameBackingIsTiled): Deleted. This was mis-named;
-                                                    it really asks whether the document uses tiled backing, but does not check for main frame.
-                                                    * rendering/RenderLayerCompositor.h:
-                                                    * rendering/RenderWidget.cpp:
-                                                    (WebCore::RenderWidget::paintContents): No need to do frame overlap testing for
-                                                    compositing now.
-
</del><span class="cx">                                             2015-05-12  Dana Burkart
</span><span class="cx">                                             Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                                             dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                                    Merge r183927. rdar://problem/20854785
</del><ins>+                                                    Merge r183943. rdar://problem/19913748
</ins><span class="cx"> 
</span><del>-                                                2015-05-07  Eric Carlson  &lt;eric.carlson@apple.com&gt;
</del><ins>+                                                2015-05-07  Simon Fraser  &lt;simon.fraser@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                                        [Mac] Playback target isn't set on new element
-                                                        https://bugs.webkit.org/show_bug.cgi?id=144724
</del><ins>+                                                        Remove the WK1-only code path for independently composited iframes
+                                                        https://bugs.webkit.org/show_bug.cgi?id=144722
</ins><span class="cx"> 
</span><del>-                                                        Reviewed by Jer Noble.
</del><ins>+                                                        Reviewed by Dean Jackson.
</ins><span class="cx"> 
</span><del>-                                                        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
-                                                        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
-                                                        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Call setShouldPlayToPlaybackTarget
-                                                        if necessary.
-                                                        (WebCore::MediaPlayerPrivateAVFoundationObjC::setShouldPlayToPlaybackTarget): Remember
-                                                        the setting in case we don't have an AVPlayer yet.
</del><ins>+                                                        In WebKit1 on Mac, we allowed iframes to be composited independently of their
+                                                        parent document, relying on the fact that the frame's platform view can host
+                                                        a layer-backed view. However, this ran into bugs (rdar://problem/18862298),
+                                                        and triggers the assertion at the end of FrameView::updateLayoutAndStyleIfNeededRecursive(),
+                                                        because the compositing update after a layout can dirty style in notifyIFramesOfCompositingChange().
</ins><span class="cx"> 
</span><ins>+                                                        Removing the WK1-only code path solves these problems. It also eliminates the need
+                                                        to do compositing-specific frame overlap testing.
+
+                                                        * page/FrameView.cpp:
+                                                        (WebCore::FrameView::setIsOverlapped): No need to do compositing-related things here.
+                                                        Any iframe that gets composited will participate in the normal compositing overlap
+                                                        testing in its parent frame.
+                                                        (WebCore::FrameView::hasCompositedContentIncludingDescendants): Deleted.
+                                                        (WebCore::FrameView::hasCompositingAncestor): Deleted.
+                                                        * page/FrameView.h:
+                                                        * rendering/RenderLayerCompositor.cpp: Replace ownerElement() checks in this file
+                                                        with an isMainFrameCompositor() for readability. Some 0-&gt;nullptr.
+                                                        (WebCore::RenderLayerCompositor::cacheAcceleratedCompositingFlags):
+                                                        (WebCore::RenderLayerCompositor::chromeClient):
+                                                        (WebCore::RenderLayerCompositor::enclosingCompositorFlushingLayers):
+                                                        (WebCore::RenderLayerCompositor::updateCompositingLayers):
+                                                        (WebCore::RenderLayerCompositor::appendDocumentOverlayLayers):
+                                                        (WebCore::RenderLayerCompositor::updateBacking):
+                                                        (WebCore::RenderLayerCompositor::layerTreeAsText):
+                                                        (WebCore::RenderLayerCompositor::frameContentsCompositor):
+                                                        (WebCore::RenderLayerCompositor::setIsInWindow):
+                                                        (WebCore::RenderLayerCompositor::requiresCompositingForScrollableFrame):
+                                                        (WebCore::RenderLayerCompositor::requiresCompositingForFrame): frameRenderer.requiresAcceleratedCompositing()
+                                                        already bails on no content RenderView, so the shouldPropagateCompositingToEnclosingFrame() check does
+                                                        nothing and is removed.
+                                                        (WebCore::RenderLayerCompositor::isAsyncScrollableStickyLayer):
+                                                        (WebCore::RenderLayerCompositor::requiresScrollLayer):
+                                                        (WebCore::RenderLayerCompositor::documentUsesTiledBacking):
+                                                        (WebCore::RenderLayerCompositor::isMainFrameCompositor):
+                                                        (WebCore::RenderLayerCompositor::shouldCompositeOverflowControls):
+                                                        (WebCore::RenderLayerCompositor::requiresOverhangAreasLayer):
+                                                        (WebCore::RenderLayerCompositor::requiresContentShadowLayer):
+                                                        (WebCore::RenderLayerCompositor::updateLayerForTopOverhangArea):
+                                                        (WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
+                                                        (WebCore::RenderLayerCompositor::updateLayerForHeader):
+                                                        (WebCore::RenderLayerCompositor::updateLayerForFooter):
+                                                        (WebCore::RenderLayerCompositor::ensureRootLayer): Main frame attaches via ChromeClient,
+                                                        all other frames attach via parent frame.
+                                                        (WebCore::RenderLayerCompositor::notifyIFramesOfCompositingChange): This call to
+                                                        scheduleSetNeedsStyleRecalc(SyntheticStyleChange) was the source of dirtying style after
+                                                        layout, but is no longer needed so remove it.
+                                                        (WebCore::RenderLayerCompositor::registerAllViewportConstrainedLayers):
+                                                        (WebCore::RenderLayerCompositor::unregisterAllViewportConstrainedLayers):
+                                                        (WebCore::RenderLayerCompositor::scrollingCoordinator):
+                                                        (WebCore::RenderLayerCompositor::graphicsLayerFactory):
+                                                        (WebCore::RenderLayerCompositor::allowsIndependentlyCompositedFrames): Deleted.
+                                                        (WebCore::RenderLayerCompositor::shouldPropagateCompositingToEnclosingFrame): Deleted.
+                                                        (WebCore::RenderLayerCompositor::mainFrameBackingIsTiled): Deleted. This was mis-named;
+                                                        it really asks whether the document uses tiled backing, but does not check for main frame.
+                                                        * rendering/RenderLayerCompositor.h:
+                                                        * rendering/RenderWidget.cpp:
+                                                        (WebCore::RenderWidget::paintContents): No need to do frame overlap testing for
+                                                        compositing now.
+
</ins><span class="cx">                                                 2015-05-12  Dana Burkart
</span><span class="cx">                                                 Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                                                 dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                                        Merge r183909. rdar://problem/18894598
</del><ins>+                                                        Merge r183927. rdar://problem/20854785
</ins><span class="cx"> 
</span><del>-                                                    2015-05-06  Daniel Bates  &lt;dabates@apple.com&gt;
</del><ins>+                                                    2015-05-07  Eric Carlson  &lt;eric.carlson@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                                            [iOS][WK2] Pause/resume database thread when UIProcess enters/leaves the background
-                                                            https://bugs.webkit.org/show_bug.cgi?id=144657
-                                                            &lt;rdar://problem/18894598&gt;
</del><ins>+                                                            [Mac] Playback target isn't set on new element
+                                                            https://bugs.webkit.org/show_bug.cgi?id=144724
</ins><span class="cx"> 
</span><del>-                                                            Reviewed by Andy Estes.
</del><ins>+                                                            Reviewed by Jer Noble.
</ins><span class="cx"> 
</span><del>-                                                            Export WebCore functionality to pause and resume the database thread so that we can
-                                                            make use of this functionality from WebKit2.
</del><ins>+                                                            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h:
+                                                            * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
+                                                            (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer): Call setShouldPlayToPlaybackTarget
+                                                            if necessary.
+                                                            (WebCore::MediaPlayerPrivateAVFoundationObjC::setShouldPlayToPlaybackTarget): Remember
+                                                            the setting in case we don't have an AVPlayer yet.
</ins><span class="cx"> 
</span><del>-                                                            * Modules/webdatabase/AbstractDatabaseServer.h:
-                                                            * Modules/webdatabase/DatabaseManager.cpp:
-                                                            (WebCore::DatabaseManager::setPauseAllDatabases): Added; turns around and calls DatabaseServer::setPauseAllDatabases().
-                                                            * Modules/webdatabase/DatabaseManager.h:
-                                                            * Modules/webdatabase/DatabaseServer.cpp:
-                                                            (WebCore::DatabaseServer::setPauseAllDatabases): Added; turns around and calls
-                                                            DatabaseTracker::tracker().setDatabasesPaused() to pause or resume the database thread.
-                                                            For now, we guard this call with PLATFORM(IOS). We'll look to remove this guard once
-                                                            we fix &lt;https://bugs.webkit.org/show_bug.cgi?id=144660&gt;.
-                                                            * Modules/webdatabase/DatabaseServer.h:
-
</del><span class="cx">                                                     2015-05-12  Dana Burkart
</span><del>-                                                    Dana Burkart  &lt;dburkart@apple.com&gt;
</del><ins>+                                                    Dana Burkart  &lt;dburkart@apple.com
+                                                    dburkart@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                                            Merge r183942. rdar://problem/20049088
</del><ins>+                                                            Merge r183909. rdar://problem/18894598
</ins><span class="cx"> 
</span><del>-                                                        2015-05-06  Dean Jackson  &lt;dino@apple.com&gt;
</del><ins>+                                                        2015-05-06  Daniel Bates  &lt;dabates@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                                                Handle backdrop views that have to tile
-                                                                https://bugs.webkit.org/show_bug.cgi?id=142317
-                                                                &lt;rdar://problem/20049088&gt;
</del><ins>+                                                                [iOS][WK2] Pause/resume database thread when UIProcess enters/leaves the background
+                                                                https://bugs.webkit.org/show_bug.cgi?id=144657
+                                                                &lt;rdar://problem/18894598&gt;
</ins><span class="cx"> 
</span><del>-                                                                Reviewed by Simon Fraser.
</del><ins>+                                                                Reviewed by Andy Estes.
</ins><span class="cx"> 
</span><del>-                                                                Take 2 - this was rolled out because Mavericks was crashing.
</del><ins>+                                                                Export WebCore functionality to pause and resume the database thread so that we can
+                                                                make use of this functionality from WebKit2.
</ins><span class="cx"> 
</span><del>-                                                                Make sure backdrop layers don't tile. If they are big
-                                                                enough, we'll leave it to the platform compositor to handle.
</del><ins>+                                                                * Modules/webdatabase/AbstractDatabaseServer.h:
+                                                                * Modules/webdatabase/DatabaseManager.cpp:
+                                                                (WebCore::DatabaseManager::setPauseAllDatabases): Added; turns around and calls DatabaseServer::setPauseAllDatabases().
+                                                                * Modules/webdatabase/DatabaseManager.h:
+                                                                * Modules/webdatabase/DatabaseServer.cpp:
+                                                                (WebCore::DatabaseServer::setPauseAllDatabases): Added; turns around and calls
+                                                                DatabaseTracker::tracker().setDatabasesPaused() to pause or resume the database thread.
+                                                                For now, we guard this call with PLATFORM(IOS). We'll look to remove this guard once
+                                                                we fix &lt;https://bugs.webkit.org/show_bug.cgi?id=144660&gt;.
+                                                                * Modules/webdatabase/DatabaseServer.h:
</ins><span class="cx"> 
</span><del>-                                                                This also fixes a bug where if a layer changed from a backdrop
-                                                                type to a tiled type, it would still retain its custom appearance
-                                                                and we'd try to add children to the wrong layer.
-
-                                                                Test: compositing/media-controls-bar-appearance-big.html
-
-                                                                * platform/graphics/ca/GraphicsLayerCA.cpp:
-                                                                (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): Check if
-                                                                a layer needs a backdrop before checking if it needs to tile.
-
</del><span class="cx">                                                         2015-05-12  Dana Burkart
</span><span class="cx">                                                         Dana Burkart  &lt;dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                                                Merge r183894. rdar://problem/20049088
</del><ins>+                                                                Merge r183942. rdar://problem/20049088
</ins><span class="cx"> 
</span><span class="cx">                                                             2015-05-06  Dean Jackson  &lt;dino@apple.com&gt;
</span><span class="cx"> 
</span><span class="lines">@@ -507,6 +584,8 @@
</span><span class="cx"> 
</span><span class="cx">                                                                     Reviewed by Simon Fraser.
</span><span class="cx"> 
</span><ins>+                                                                    Take 2 - this was rolled out because Mavericks was crashing.
+
</ins><span class="cx">                                                                     Make sure backdrop layers don't tile. If they are big
</span><span class="cx">                                                                     enough, we'll leave it to the platform compositor to handle.
</span><span class="cx"> 
</span><span class="lines">@@ -520,6 +599,32 @@
</span><span class="cx">                                                                     (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): Check if
</span><span class="cx">                                                                     a layer needs a backdrop before checking if it needs to tile.
</span><span class="cx"> 
</span><ins>+                                                            2015-05-12  Dana Burkart
+                                                            Dana Burkart  &lt;dburkart@apple.com&gt;
+
+                                                                    Merge r183894. rdar://problem/20049088
+
+                                                                2015-05-06  Dean Jackson  &lt;dino@apple.com&gt;
+
+                                                                        Handle backdrop views that have to tile
+                                                                        https://bugs.webkit.org/show_bug.cgi?id=142317
+                                                                        &lt;rdar://problem/20049088&gt;
+
+                                                                        Reviewed by Simon Fraser.
+
+                                                                        Make sure backdrop layers don't tile. If they are big
+                                                                        enough, we'll leave it to the platform compositor to handle.
+
+                                                                        This also fixes a bug where if a layer changed from a backdrop
+                                                                        type to a tiled type, it would still retain its custom appearance
+                                                                        and we'd try to add children to the wrong layer.
+
+                                                                        Test: compositing/media-controls-bar-appearance-big.html
+
+                                                                        * platform/graphics/ca/GraphicsLayerCA.cpp:
+                                                                        (WebCore::GraphicsLayerCA::commitLayerChangesBeforeSublayers): Check if
+                                                                        a layer needs a backdrop before checking if it needs to tile.
+
</ins><span class="cx"> 2015-05-06  Brent Fulgham  &lt;bfulgham@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Scroll-snap points do not handle margins and padding propertly
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepageFrameViewcpp"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/FrameView.cpp (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/FrameView.cpp        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/FrameView.cpp        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -2933,7 +2933,11 @@
</span><span class="cx">     frame().loader().client().dispatchDidLayout();
</span><span class="cx"> 
</span><span class="cx">     updateWidgetPositions();
</span><del>-    
</del><ins>+
+#if ENABLE(CSS_SCROLL_SNAP)
+    updateSnapOffsets();
+#endif
+
</ins><span class="cx">     // layout() protects FrameView, but it still can get destroyed when updateEmbeddedObjects()
</span><span class="cx">     // is called through the post layout timer.
</span><span class="cx">     Ref&lt;FrameView&gt; protect(*this);
</span><span class="lines">@@ -2955,15 +2959,7 @@
</span><span class="cx">     sendResizeEventIfNeeded();
</span><span class="cx">     viewportContentsChanged();
</span><span class="cx"> 
</span><del>-#if ENABLE(CSS_SCROLL_SNAP)
-    if (!frame().isMainFrame()) {
-        updateSnapOffsets();
-#if PLATFORM(MAC)
-        if (ScrollAnimator* scrollAnimator = existingScrollAnimator())
-            return scrollAnimator-&gt;updateScrollAnimatorsAndTimers();
-#endif
-    }
-#endif
</del><ins>+    updateScrollSnapState();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> IntSize FrameView::sizeForResizeEvent() const
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingAsyncScrollingCoordinatorcpp"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -562,8 +562,33 @@
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if PLATFORM(COCOA)
</span><ins>+void AsyncScrollingCoordinator::setActiveScrollSnapIndices(ScrollingNodeID scrollingNodeID, unsigned horizontalIndex, unsigned verticalIndex)
+{
+    ASSERT(isMainThread());
+    
+    if (!m_page)
+        return;
+    
+    FrameView* frameView = frameViewForScrollingNode(scrollingNodeID);
+    if (!frameView)
+        return;
+    
+    if (scrollingNodeID == frameView-&gt;scrollLayerID()) {
+        frameView-&gt;setCurrentHorizontalSnapPointIndex(horizontalIndex);
+        frameView-&gt;setCurrentVerticalSnapPointIndex(verticalIndex);
+        return;
+    }
+    
+    // Overflow-scroll area.
+    if (ScrollableArea* scrollableArea = frameView-&gt;scrollableAreaForScrollLayerID(scrollingNodeID)) {
+        scrollableArea-&gt;setCurrentHorizontalSnapPointIndex(horizontalIndex);
+        scrollableArea-&gt;setCurrentVerticalSnapPointIndex(verticalIndex);
+    }
+}
+
</ins><span class="cx"> void AsyncScrollingCoordinator::deferTestsForReason(WheelEventTestTrigger::ScrollableAreaIdentifier identifier, WheelEventTestTrigger::DeferTestTriggerReason reason) const
</span><span class="cx"> {
</span><ins>+    ASSERT(isMainThread());
</ins><span class="cx">     if (!m_page || !m_page-&gt;expectsWheelEventTriggers())
</span><span class="cx">         return;
</span><span class="cx"> 
</span><span class="lines">@@ -575,6 +600,7 @@
</span><span class="cx"> 
</span><span class="cx"> void AsyncScrollingCoordinator::removeTestDeferralForReason(WheelEventTestTrigger::ScrollableAreaIdentifier identifier, WheelEventTestTrigger::DeferTestTriggerReason reason) const
</span><span class="cx"> {
</span><ins>+    ASSERT(isMainThread());
</ins><span class="cx">     if (!m_page || !m_page-&gt;expectsWheelEventTriggers())
</span><span class="cx">         return;
</span><span class="cx"> 
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingAsyncScrollingCoordinatorh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AsyncScrollingCoordinator.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -57,6 +57,7 @@
</span><span class="cx">     WEBCORE_EXPORT void scheduleUpdateScrollPositionAfterAsyncScroll(ScrollingNodeID, const FloatPoint&amp;, bool programmaticScroll, SetOrSyncScrollingLayerPosition);
</span><span class="cx"> 
</span><span class="cx"> #if PLATFORM(COCOA)
</span><ins>+    void setActiveScrollSnapIndices(ScrollingNodeID, unsigned horizontalIndex, unsigned verticalIndex);
</ins><span class="cx">     void deferTestsForReason(WheelEventTestTrigger::ScrollableAreaIdentifier, WheelEventTestTrigger::DeferTestTriggerReason) const;
</span><span class="cx">     void removeTestDeferralForReason(WheelEventTestTrigger::ScrollableAreaIdentifier, WheelEventTestTrigger::DeferTestTriggerReason) const;
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingAxisScrollSnapOffsetsh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AxisScrollSnapOffsets.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AxisScrollSnapOffsets.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/AxisScrollSnapOffsets.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -1,5 +1,5 @@
</span><span class="cx"> /*
</span><del>- * Copyright (C) 2014 Apple Inc. All rights reserved.
</del><ins>+ * Copyright (C) 2014-2015 Apple Inc. All rights reserved.
</ins><span class="cx">  *
</span><span class="cx">  * Redistribution and use in source and binary forms, with or without
</span><span class="cx">  * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -44,12 +44,14 @@
</span><span class="cx"> // as well as a VelocityType indicating the velocity (e.g. float, CGFloat, etc.) This function is templated because the UI process will now
</span><span class="cx"> // use pixel snapped floats to represent snap offsets rather than LayoutUnits.
</span><span class="cx"> template &lt;typename LayoutType, typename VelocityType&gt;
</span><del>-LayoutType closestSnapOffset(const Vector&lt;LayoutType&gt;&amp; snapOffsets, LayoutType scrollDestination, VelocityType velocity)
</del><ins>+LayoutType closestSnapOffset(const Vector&lt;LayoutType&gt;&amp; snapOffsets, LayoutType scrollDestination, VelocityType velocity, unsigned&amp; activeSnapIndex)
</ins><span class="cx"> {
</span><span class="cx">     ASSERT(snapOffsets.size());
</span><ins>+    activeSnapIndex = 0;
</ins><span class="cx">     if (scrollDestination &lt;= snapOffsets.first())
</span><span class="cx">         return snapOffsets.first();
</span><span class="cx"> 
</span><ins>+    activeSnapIndex = snapOffsets.size() - 1;
</ins><span class="cx">     if (scrollDestination &gt;= snapOffsets.last())
</span><span class="cx">         return snapOffsets.last();
</span><span class="cx"> 
</span><span class="lines">@@ -70,10 +72,13 @@
</span><span class="cx">     LayoutType lowerSnapPosition = snapOffsets[lowerIndex];
</span><span class="cx">     LayoutType upperSnapPosition = snapOffsets[upperIndex];
</span><span class="cx">     // Nonzero velocity indicates a flick gesture. Even if another snap point is closer, snap to the one in the direction of the flick gesture.
</span><del>-    if (velocity)
</del><ins>+    if (velocity) {
+        activeSnapIndex = (velocity &lt; 0) ? lowerIndex : upperIndex;
</ins><span class="cx">         return velocity &lt; 0 ? lowerSnapPosition : upperSnapPosition;
</span><ins>+    }
</ins><span class="cx"> 
</span><span class="cx">     bool isCloserToLowerSnapPosition = scrollDestination - lowerSnapPosition &lt;= upperSnapPosition - scrollDestination;
</span><ins>+    activeSnapIndex = isCloserToLowerSnapPosition ? lowerIndex : upperIndex;
</ins><span class="cx">     return isCloserToLowerSnapPosition ? lowerSnapPosition : upperSnapPosition;
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingScrollingTreeh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ScrollingTree.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ScrollingTree.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ScrollingTree.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -100,6 +100,7 @@
</span><span class="cx">     
</span><span class="cx"> #if PLATFORM(MAC)
</span><span class="cx">     virtual void handleWheelEventPhase(PlatformWheelEventPhase) = 0;
</span><ins>+    virtual void setActiveScrollSnapIndices(ScrollingNodeID, unsigned /*horizontalIndex*/, unsigned /*verticalIndex*/) { }
</ins><span class="cx">     virtual void deferTestsForReason(WheelEventTestTrigger::ScrollableAreaIdentifier, WheelEventTestTrigger::DeferTestTriggerReason) { }
</span><span class="cx">     virtual void removeTestDeferralForReason(WheelEventTestTrigger::ScrollableAreaIdentifier, WheelEventTestTrigger::DeferTestTriggerReason) { }
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingThreadedScrollingTreecpp"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.cpp (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.cpp        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.cpp        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -123,6 +123,17 @@
</span><span class="cx">     });
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void ThreadedScrollingTree::setActiveScrollSnapIndices(ScrollingNodeID nodeID, unsigned horizontalIndex, unsigned verticalIndex)
+{
+    if (!m_scrollingCoordinator)
+        return;
+    
+    RefPtr&lt;AsyncScrollingCoordinator&gt; scrollingCoordinator = m_scrollingCoordinator;
+    RunLoop::main().dispatch([scrollingCoordinator, nodeID, horizontalIndex, verticalIndex] {
+        scrollingCoordinator-&gt;setActiveScrollSnapIndices(nodeID, horizontalIndex, verticalIndex);
+    });
+}
+
</ins><span class="cx"> void ThreadedScrollingTree::deferTestsForReason(WheelEventTestTrigger::ScrollableAreaIdentifier identifier, WheelEventTestTrigger::DeferTestTriggerReason reason)
</span><span class="cx"> {
</span><span class="cx">     if (!m_scrollingCoordinator)
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingThreadedScrollingTreeh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/ThreadedScrollingTree.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -62,6 +62,7 @@
</span><span class="cx">     virtual void scrollingTreeNodeDidScroll(ScrollingNodeID, const FloatPoint&amp; scrollPosition, SetOrSyncScrollingLayerPosition = SyncScrollingLayerPosition) override;
</span><span class="cx"> #if PLATFORM(MAC)
</span><span class="cx">     void handleWheelEventPhase(PlatformWheelEventPhase) override;
</span><ins>+    void setActiveScrollSnapIndices(ScrollingNodeID, unsigned horizontalIndex, unsigned verticalIndex) override;
</ins><span class="cx">     void deferTestsForReason(WheelEventTestTrigger::ScrollableAreaIdentifier, WheelEventTestTrigger::DeferTestTriggerReason) override;
</span><span class="cx">     void removeTestDeferralForReason(WheelEventTestTrigger::ScrollableAreaIdentifier, WheelEventTestTrigger::DeferTestTriggerReason) override;
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorepagescrollingmacScrollingTreeFrameScrollingNodeMacmm"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/page/scrolling/mac/ScrollingTreeFrameScrollingNodeMac.mm        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -184,6 +184,10 @@
</span><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx">     m_scrollController.handleWheelEvent(wheelEvent);
</span><ins>+#if ENABLE(CSS_SCROLL_SNAP)
+    if (m_scrollController.activeScrollSnapIndexDidChange())
+        scrollingTree().setActiveScrollSnapIndices(scrollingNodeID(), m_scrollController.activeScrollSnapIndexForAxis(ScrollEventAxis::Horizontal), m_scrollController.activeScrollSnapIndexForAxis(ScrollEventAxis::Vertical));
+#endif
</ins><span class="cx">     scrollingTree().setOrClearLatchedNode(wheelEvent, scrollingNodeID());
</span><span class="cx">     scrollingTree().handleWheelEventPhase(wheelEvent.phase());
</span><span class="cx"> }
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformScrollAnimatorcpp"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.cpp (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.cpp        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.cpp        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -87,6 +87,16 @@
</span><span class="cx"> {
</span><span class="cx">     return m_scrollController.processWheelEventForScrollSnap(wheelEvent);
</span><span class="cx"> }
</span><ins>+
+bool ScrollAnimator::activeScrollSnapIndexDidChange() const
+{
+    return m_scrollController.activeScrollSnapIndexDidChange();
+}
+
+unsigned ScrollAnimator::activeScrollSnapIndexForAxis(ScrollEventAxis axis) const
+{
+    return m_scrollController.activeScrollSnapIndexForAxis(axis);
+}
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> bool ScrollAnimator::handleWheelEvent(const PlatformWheelEvent&amp; e)
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformScrollAnimatorh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollAnimator.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -130,6 +130,8 @@
</span><span class="cx">     void updateScrollAnimatorsAndTimers();
</span><span class="cx">     LayoutUnit scrollOffsetOnAxis(ScrollEventAxis) const override;
</span><span class="cx">     void immediateScrollOnAxis(ScrollEventAxis, float delta) override;
</span><ins>+    bool activeScrollSnapIndexDidChange() const;
+    unsigned activeScrollSnapIndexForAxis(ScrollEventAxis) const;
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> protected:
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformScrollableAreacpp"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.cpp (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.cpp        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.cpp        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -46,6 +46,7 @@
</span><span class="cx">     virtual ~SameSizeAsScrollableArea();
</span><span class="cx"> #if ENABLE(CSS_SCROLL_SNAP)
</span><span class="cx">     void* pointers[3];
</span><ins>+    unsigned currentIndices[2];
</ins><span class="cx"> #else
</span><span class="cx">     void* pointer;
</span><span class="cx"> #endif
</span><span class="lines">@@ -188,7 +189,14 @@
</span><span class="cx">     if (!isScrollableOrRubberbandable())
</span><span class="cx">         return false;
</span><span class="cx"> 
</span><del>-    return scrollAnimator().handleWheelEvent(wheelEvent);
</del><ins>+    bool handledEvent = scrollAnimator().handleWheelEvent(wheelEvent);
+#if ENABLE(CSS_SCROLL_SNAP) &amp;&amp; PLATFORM(MAC)
+    if (scrollAnimator().activeScrollSnapIndexDidChange()) {
+        setCurrentHorizontalSnapPointIndex(scrollAnimator().activeScrollSnapIndexForAxis(ScrollEventAxis::Horizontal));
+        setCurrentVerticalSnapPointIndex(scrollAnimator().activeScrollSnapIndexForAxis(ScrollEventAxis::Vertical));
+    }
+#endif
+    return handledEvent;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> #if ENABLE(TOUCH_EVENTS)
</span><span class="lines">@@ -409,14 +417,64 @@
</span><span class="cx"> void ScrollableArea::clearHorizontalSnapOffsets()
</span><span class="cx"> {
</span><span class="cx">     m_horizontalSnapOffsets = nullptr;
</span><ins>+    m_currentHorizontalSnapPointIndex = 0;
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void ScrollableArea::clearVerticalSnapOffsets()
</span><span class="cx"> {
</span><span class="cx">     m_verticalSnapOffsets = nullptr;
</span><ins>+    m_currentVerticalSnapPointIndex = 0;
</ins><span class="cx"> }
</span><ins>+
+IntPoint ScrollableArea::nearestActiveSnapPoint(const IntPoint&amp; currentPosition)
+{
+    if (!horizontalSnapOffsets() &amp;&amp; !verticalSnapOffsets())
+        return currentPosition;
+    
+    if (!existingScrollAnimator())
+        return currentPosition;
+    
+    IntPoint correctedPosition = currentPosition;
+    
+    if (horizontalSnapOffsets()) {
+        const auto&amp; horizontal = *horizontalSnapOffsets();
+        
+        size_t activeIndex = currentHorizontalSnapPointIndex();
+        if (activeIndex &lt; horizontal.size())
+            correctedPosition.setX(horizontal[activeIndex].toInt());
+    }
+    
+    if (verticalSnapOffsets()) {
+        const auto&amp; vertical = *verticalSnapOffsets();
+        
+        size_t activeIndex = currentVerticalSnapPointIndex();
+        if (activeIndex &lt; vertical.size())
+            correctedPosition.setY(vertical[activeIndex].toInt());
+    }
+
+    return correctedPosition;
+}
+
+void ScrollableArea::updateScrollSnapState()
+{
+#if PLATFORM(MAC)
+    if (ScrollAnimator* scrollAnimator = existingScrollAnimator())
+        scrollAnimator-&gt;updateScrollAnimatorsAndTimers();
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><ins>+    IntPoint currentPosition = scrollPosition();
+    IntPoint correctedPosition = nearestActiveSnapPoint(currentPosition);
+    
+    if (correctedPosition != currentPosition)
+        scrollToOffsetWithoutAnimation(correctedPosition);
+}
+#else
+void ScrollableArea::updateScrollSnapState()
+{
+}
+#endif
+
+
</ins><span class="cx"> void ScrollableArea::serviceScrollAnimations()
</span><span class="cx"> {
</span><span class="cx">     if (ScrollAnimator* scrollAnimator = existingScrollAnimator())
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformScrollableAreah"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/ScrollableArea.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -1,5 +1,5 @@
</span><span class="cx"> /*
</span><del>- * Copyright (C) 2008, 2011, 2014 Apple Inc. All Rights Reserved.
</del><ins>+ * Copyright (C) 2008, 2011, 2014-2015 Apple Inc. All Rights Reserved.
</ins><span class="cx">  *
</span><span class="cx">  * Redistribution and use in source and binary forms, with or without
</span><span class="cx">  * modification, are permitted provided that the following conditions
</span><span class="lines">@@ -66,8 +66,15 @@
</span><span class="cx">     void setVerticalSnapOffsets(std::unique_ptr&lt;Vector&lt;LayoutUnit&gt;&gt;);
</span><span class="cx">     void clearHorizontalSnapOffsets();
</span><span class="cx">     void clearVerticalSnapOffsets();
</span><ins>+    unsigned currentHorizontalSnapPointIndex() const { return m_currentHorizontalSnapPointIndex; }
+    void setCurrentHorizontalSnapPointIndex(unsigned index) { m_currentHorizontalSnapPointIndex = index; }
+    unsigned currentVerticalSnapPointIndex() const { return m_currentVerticalSnapPointIndex; }
+    void setCurrentVerticalSnapPointIndex(unsigned index) { m_currentVerticalSnapPointIndex = index; }
+    IntPoint nearestActiveSnapPoint(const IntPoint&amp;);
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><ins>+    void updateScrollSnapState();
+
</ins><span class="cx"> #if ENABLE(TOUCH_EVENTS)
</span><span class="cx">     virtual bool isTouchScrollable() const { return false; }
</span><span class="cx">     virtual bool handleTouchEvent(const PlatformTouchEvent&amp;);
</span><span class="lines">@@ -305,6 +312,8 @@
</span><span class="cx"> #if ENABLE(CSS_SCROLL_SNAP)
</span><span class="cx">     std::unique_ptr&lt;Vector&lt;LayoutUnit&gt;&gt; m_horizontalSnapOffsets;
</span><span class="cx">     std::unique_ptr&lt;Vector&lt;LayoutUnit&gt;&gt; m_verticalSnapOffsets;
</span><ins>+    unsigned m_currentHorizontalSnapPointIndex { 0 };
+    unsigned m_currentVerticalSnapPointIndex { 0 };
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx">     // There are 8 possible combinations of writing mode and direction. Scroll origin will be non-zero in the x or y axis
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformcocoaScrollControllerh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -97,6 +97,11 @@
</span><span class="cx">     {
</span><span class="cx">         return 1.0f;
</span><span class="cx">     }
</span><ins>+
+    virtual unsigned activeScrollOffsetIndex(ScrollEventAxis) const
+    {
+        return 0;
+    }
</ins><span class="cx"> #endif
</span><span class="cx"> };
</span><span class="cx"> 
</span><span class="lines">@@ -114,6 +119,10 @@
</span><span class="cx">     bool processWheelEventForScrollSnap(const PlatformWheelEvent&amp;);
</span><span class="cx">     void updateScrollAnimatorsAndTimers(const ScrollableArea&amp;);
</span><span class="cx">     void updateScrollSnapPoints(ScrollEventAxis, const Vector&lt;LayoutUnit&gt;&amp;);
</span><ins>+    unsigned activeScrollSnapIndexForAxis(ScrollEventAxis) const;
+    void setActiveScrollSnapIndexForAxis(ScrollEventAxis, unsigned);
+    bool activeScrollSnapIndexDidChange() const { return m_activeScrollSnapIndexDidChange; }
+    void setScrollSnapIndexDidChange(bool state) { m_activeScrollSnapIndexDidChange = state; }
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> private:
</span><span class="lines">@@ -172,6 +181,7 @@
</span><span class="cx">     bool m_momentumScrollInProgress { false };
</span><span class="cx">     bool m_ignoreMomentumScrolls { false };
</span><span class="cx">     bool m_snapRubberbandTimerIsActive { false };
</span><ins>+    bool m_activeScrollSnapIndexDidChange { false };
</ins><span class="cx"> };
</span><span class="cx">     
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformcocoaScrollControllermm"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.mm (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.mm        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollController.mm        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -685,6 +685,26 @@
</span><span class="cx">     snapState.m_glidePhaseShift = acos((snapState.m_glideInitialWheelDelta - targetFinalWheelDelta) / (snapState.m_glideInitialWheelDelta + targetFinalWheelDelta));
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+unsigned ScrollController::activeScrollSnapIndexForAxis(ScrollEventAxis axis) const
+{
+    if ((axis == ScrollEventAxis::Horizontal) &amp;&amp; !m_horizontalScrollSnapState)
+        return 0;
+    if ((axis == ScrollEventAxis::Vertical) &amp;&amp; !m_verticalScrollSnapState)
+        return 0;
+    
+    const ScrollSnapAnimatorState&amp; snapState = scrollSnapPointState(axis);
+    return snapState.m_activeSnapIndex;
+}
+
+void ScrollController::setActiveScrollSnapIndexForAxis(ScrollEventAxis axis, unsigned index)
+{
+    auto* snapState = (axis == ScrollEventAxis::Horizontal) ? m_horizontalScrollSnapState.get() : m_verticalScrollSnapState.get();
+    if (!snapState)
+        return;
+
+    snapState-&gt;m_activeSnapIndex = index;
+}
+
</ins><span class="cx"> void ScrollController::beginScrollSnapAnimation(ScrollEventAxis axis, ScrollSnapState newState)
</span><span class="cx"> {
</span><span class="cx">     ASSERT(newState == ScrollSnapState::Gliding || newState == ScrollSnapState::Snapping);
</span><span class="lines">@@ -701,10 +721,12 @@
</span><span class="cx">     
</span><span class="cx">     projectedScrollDestination = std::min(std::max(LayoutUnit(projectedScrollDestination / scaleFactor), snapState.m_snapOffsets.first()), snapState.m_snapOffsets.last());
</span><span class="cx">     snapState.m_initialOffset = offset;
</span><del>-    snapState.m_targetOffset = scaleFactor * closestSnapOffset&lt;LayoutUnit, float&gt;(snapState.m_snapOffsets, projectedScrollDestination, initialWheelDelta);
</del><ins>+    m_activeScrollSnapIndexDidChange = false;
+    snapState.m_targetOffset = scaleFactor * closestSnapOffset&lt;LayoutUnit, float&gt;(snapState.m_snapOffsets, projectedScrollDestination, initialWheelDelta, snapState.m_activeSnapIndex);
</ins><span class="cx">     if (snapState.m_initialOffset == snapState.m_targetOffset)
</span><span class="cx">         return;
</span><span class="cx">     
</span><ins>+    m_activeScrollSnapIndexDidChange = true;
</ins><span class="cx">     snapState.m_currentState = newState;
</span><span class="cx">     if (newState == ScrollSnapState::Gliding) {
</span><span class="cx">         snapState.m_shouldOverrideWheelEvent = true;
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformcocoaScrollSnapAnimatorStateh"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.h (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.h        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.h        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -59,12 +59,13 @@
</span><span class="cx">     LayoutUnit m_targetOffset;
</span><span class="cx">     // Used to track gliding behavior.
</span><span class="cx">     LayoutUnit m_beginTrackingWheelDeltaOffset;
</span><del>-    int m_numWheelDeltasTracked;
</del><ins>+    int m_numWheelDeltasTracked { 0 };
+    unsigned m_activeSnapIndex { 0 };
</ins><span class="cx">     float m_wheelDeltaWindow[wheelDeltaWindowSize];
</span><del>-    float m_glideMagnitude;
-    float m_glidePhaseShift;
-    float m_glideInitialWheelDelta;
-    bool m_shouldOverrideWheelEvent;
</del><ins>+    float m_glideMagnitude { 0 };
+    float m_glidePhaseShift { 0 };
+    float m_glideInitialWheelDelta { 0 };
+    bool m_shouldOverrideWheelEvent { false };
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCoreplatformcocoaScrollSnapAnimatorStatemm"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.mm (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.mm        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/platform/cocoa/ScrollSnapAnimatorState.mm        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -37,11 +37,6 @@
</span><span class="cx">     , m_initialOffset(0)
</span><span class="cx">     , m_targetOffset(0)
</span><span class="cx">     , m_beginTrackingWheelDeltaOffset(0)
</span><del>-    , m_numWheelDeltasTracked(0)
-    , m_glideMagnitude(0)
-    , m_glidePhaseShift(0)
-    , m_glideInitialWheelDelta(0)
-    , m_shouldOverrideWheelEvent(false)
</del><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebCorerenderingRenderLayercpp"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebCore/rendering/RenderLayer.cpp (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebCore/rendering/RenderLayer.cpp        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebCore/rendering/RenderLayer.cpp        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -3461,6 +3461,12 @@
</span><span class="cx"> 
</span><span class="cx">     computeScrollDimensions();
</span><span class="cx"> 
</span><ins>+#if ENABLE(CSS_SCROLL_SNAP)
+    // FIXME: Ensure that offsets are also updated in case of programmatic style changes.
+    // https://bugs.webkit.org/show_bug.cgi?id=135964
+    updateSnapOffsets();
+#endif
+
</ins><span class="cx">     if (box-&gt;style().overflowX() != OMARQUEE &amp;&amp; !isRubberBandInProgress()) {
</span><span class="cx">         // Layout may cause us to be at an invalid scroll position. In this case we need
</span><span class="cx">         // to pull our scroll offsets back to the max (or push them up to the min).
</span><span class="lines">@@ -3488,15 +3494,7 @@
</span><span class="cx">     if (compositor().updateLayerCompositingState(*this))
</span><span class="cx">         compositor().setCompositingLayersNeedRebuild();
</span><span class="cx"> 
</span><del>-#if ENABLE(CSS_SCROLL_SNAP)
-    // FIXME: Ensure that offsets are also updated in case of programmatic style changes.
-    // https://bugs.webkit.org/show_bug.cgi?id=135964
-    updateSnapOffsets();
-#if PLATFORM(MAC)
-    if (ScrollAnimator* scrollAnimator = existingScrollAnimator())
-        return scrollAnimator-&gt;updateScrollAnimatorsAndTimers();
-#endif
-#endif
</del><ins>+    updateScrollSnapState();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> bool RenderLayer::overflowControlsIntersectRect(const IntRect&amp; localRect) const
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebKit2/ChangeLog (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebKit2/ChangeLog        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebKit2/ChangeLog        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -2,188 +2,187 @@
</span><span class="cx"> Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx"> dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-        Merge r184121. rdar://problem/20774613
</del><ins>+        Merge r184139. rdar://problem/20125088
</ins><span class="cx"> 
</span><del>-    2015-05-11  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</del><ins>+    2015-05-11  Brent Fulgham  &lt;bfulgham@apple.com&gt;
</ins><span class="cx"> 
</span><del>-            Unreviewed build fix
</del><ins>+            Scroll snap logic should be triggered when resizing the WebView
+            https://bugs.webkit.org/show_bug.cgi?id=142590
+            &lt;rdar://problem/20125088&gt;
</ins><span class="cx"> 
</span><del>-            Unreviewed.
</del><ins>+            Reviewed by Simon Fraser.
</ins><span class="cx"> 
</span><del>-            * UIProcess/API/APIUserContentExtensionStore.cpp:
-            (API::compiledToFile):
</del><ins>+            * UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm:
+            (RemoteScrollingCoordinatorProxy::closestSnapOffsetForMainFrameScrolling): Modify use of 'closestSnapOffset' to satisfy the additional
+            argument I added. This is currently not used for anything on iOS.
+            * UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm: Ditto.
</ins><span class="cx"> 
</span><span class="cx">     2015-05-12  Dana Burkart
</span><span class="cx">     Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">     dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-            Merge r184116. rdar://problem/20774613
</del><ins>+            Merge r184121. rdar://problem/20774613
</ins><span class="cx"> 
</span><del>-        2015-05-11  Alex Christensen  &lt;achristensen@webkit.org&gt;
</del><ins>+        2015-05-11  Myles C. Maxfield  &lt;mmaxfield@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                [Content Extensions] Support domain-specific rules and exceptions.
-                https://bugs.webkit.org/show_bug.cgi?id=144833
</del><ins>+                Unreviewed build fix
</ins><span class="cx"> 
</span><del>-                Reviewed by Darin Adler.
</del><ins>+                Unreviewed.
</ins><span class="cx"> 
</span><del>-                * Shared/WebCompiledContentExtension.cpp:
-                (WebKit::WebCompiledContentExtension::filtersWithoutDomainsBytecode):
-                (WebKit::WebCompiledContentExtension::filtersWithoutDomainsBytecodeLength):
-                (WebKit::WebCompiledContentExtension::filtersWithDomainsBytecode):
-                (WebKit::WebCompiledContentExtension::filtersWithDomainsBytecodeLength):
-                (WebKit::WebCompiledContentExtension::domainFiltersBytecode):
-                (WebKit::WebCompiledContentExtension::domainFiltersBytecodeLength):
-                (WebKit::WebCompiledContentExtension::bytecode): Deleted.
-                (WebKit::WebCompiledContentExtension::bytecodeLength): Deleted.
-                * Shared/WebCompiledContentExtension.h:
-                * Shared/WebCompiledContentExtensionData.cpp:
-                (WebKit::WebCompiledContentExtensionData::encode):
-                (WebKit::WebCompiledContentExtensionData::decode):
-                * Shared/WebCompiledContentExtensionData.h:
-                (WebKit::WebCompiledContentExtensionData::WebCompiledContentExtensionData):
</del><span class="cx">                 * UIProcess/API/APIUserContentExtensionStore.cpp:
</span><del>-                (API::ContentExtensionMetaData::fileSize):
-                (API::encodeContentExtensionMetaData):
-                (API::decodeContentExtensionMetaData):
</del><span class="cx">                 (API::compiledToFile):
</span><del>-                (API::createExtension):
-                Keep track of 3 different types of bytecode to be able to handle domain-specific rules.
</del><span class="cx"> 
</span><span class="cx">         2015-05-12  Dana Burkart
</span><span class="cx">         Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">         dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                Merge r184026. rdar://problem/20757196
</del><ins>+                Merge r184116. rdar://problem/20774613
</ins><span class="cx"> 
</span><del>-            2015-05-08  Dan Bernstein  &lt;mitz@apple.com&gt;
</del><ins>+            2015-05-11  Alex Christensen  &lt;achristensen@webkit.org&gt;
</ins><span class="cx"> 
</span><del>-                    &lt;rdar://problem/20757196&gt; NSInternalInconsistencyException raised in -[NSString encodeWithCoder:] beneath createEncodedObject when using WKRemoteObjectEncoder for Safari AutoFill
-                    https://bugs.webkit.org/show_bug.cgi?id=144818
</del><ins>+                    [Content Extensions] Support domain-specific rules and exceptions.
+                    https://bugs.webkit.org/show_bug.cgi?id=144833
</ins><span class="cx"> 
</span><del>-                    Reviewed by Anders Carlsson.
</del><ins>+                    Reviewed by Darin Adler.
</ins><span class="cx"> 
</span><del>-                    Allow NSString instances that contain unpaired surrogates to be encoded by
-                    WKRemoteObjectCoder by encoding them directly rather than using
-                    -[NSString encodeWithCoder:].
</del><ins>+                    * Shared/WebCompiledContentExtension.cpp:
+                    (WebKit::WebCompiledContentExtension::filtersWithoutDomainsBytecode):
+                    (WebKit::WebCompiledContentExtension::filtersWithoutDomainsBytecodeLength):
+                    (WebKit::WebCompiledContentExtension::filtersWithDomainsBytecode):
+                    (WebKit::WebCompiledContentExtension::filtersWithDomainsBytecodeLength):
+                    (WebKit::WebCompiledContentExtension::domainFiltersBytecode):
+                    (WebKit::WebCompiledContentExtension::domainFiltersBytecodeLength):
+                    (WebKit::WebCompiledContentExtension::bytecode): Deleted.
+                    (WebKit::WebCompiledContentExtension::bytecodeLength): Deleted.
+                    * Shared/WebCompiledContentExtension.h:
+                    * Shared/WebCompiledContentExtensionData.cpp:
+                    (WebKit::WebCompiledContentExtensionData::encode):
+                    (WebKit::WebCompiledContentExtensionData::decode):
+                    * Shared/WebCompiledContentExtensionData.h:
+                    (WebKit::WebCompiledContentExtensionData::WebCompiledContentExtensionData):
+                    * UIProcess/API/APIUserContentExtensionStore.cpp:
+                    (API::ContentExtensionMetaData::fileSize):
+                    (API::encodeContentExtensionMetaData):
+                    (API::decodeContentExtensionMetaData):
+                    (API::compiledToFile):
+                    (API::createExtension):
+                    Keep track of 3 different types of bytecode to be able to handle domain-specific rules.
</ins><span class="cx"> 
</span><del>-                    * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
-                    (encodeString): Added. Sets an API::String as the object to encode.
-                    (encodeObject): Changed to use encodeString for NSString instances.
-                    (decodeString): Added. Gets an API::String from the dictionary and returns it as an
-                    NSString.
-                    (decodeObject): Changed to use decodeString for NSString instances.
-
</del><span class="cx">             2015-05-12  Dana Burkart
</span><span class="cx">             Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">             dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                    Merge r183937. rdar://problem/20458697
</del><ins>+                    Merge r184026. rdar://problem/20757196
</ins><span class="cx"> 
</span><del>-                2015-05-07  Jer Noble  &lt;jer.noble@apple.com&gt;
</del><ins>+                2015-05-08  Dan Bernstein  &lt;mitz@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                        [WK2][Fullscreen] Fullscreen video does not enter low-power mode.
-                        https://bugs.webkit.org/show_bug.cgi?id=144744
</del><ins>+                        &lt;rdar://problem/20757196&gt; NSInternalInconsistencyException raised in -[NSString encodeWithCoder:] beneath createEncodedObject when using WKRemoteObjectEncoder for Safari AutoFill
+                        https://bugs.webkit.org/show_bug.cgi?id=144818
</ins><span class="cx"> 
</span><del>-                        Reviewed by Darin Adler.
</del><ins>+                        Reviewed by Anders Carlsson.
</ins><span class="cx"> 
</span><del>-                        One of the requirements of entering low-power compositing mode is that no masking layers
-                        are present in any of the ancestors of the fullscreen video layer. So once our fullscreen
-                        transition animation completes, remove the mask layer entirely from our clipping layer.
-                        This means it needs to be re-created and added when entering fullscreen, rather than just
-                        at initialization time.
</del><ins>+                        Allow NSString instances that contain unpaired surrogates to be encoded by
+                        WKRemoteObjectCoder by encoding them directly rather than using
+                        -[NSString encodeWithCoder:].
</ins><span class="cx"> 
</span><del>-                        * UIProcess/mac/WKFullScreenWindowController.mm:
-                        (-[WKFullScreenWindowController initWithWindow:webView:]):
-                        (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
-                        (-[WKFullScreenWindowController _startEnterFullScreenAnimationWithDuration:]):
</del><ins>+                        * Shared/API/Cocoa/WKRemoteObjectCoder.mm:
+                        (encodeString): Added. Sets an API::String as the object to encode.
+                        (encodeObject): Changed to use encodeString for NSString instances.
+                        (decodeString): Added. Gets an API::String from the dictionary and returns it as an
+                        NSString.
+                        (decodeObject): Changed to use decodeString for NSString instances.
</ins><span class="cx"> 
</span><span class="cx">                 2015-05-12  Dana Burkart
</span><span class="cx">                 Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                 dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                        Merge r183911. rdar://problem/20702435
</del><ins>+                        Merge r183937. rdar://problem/20458697
</ins><span class="cx"> 
</span><del>-                    2015-05-06  Jer Noble  &lt;jer.noble@apple.com&gt;
</del><ins>+                    2015-05-07  Jer Noble  &lt;jer.noble@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                            [WK2][Fullscreen] Elements whose children extend beyond their bounds are clipped in fullscreen mode.
-                            https://bugs.webkit.org/show_bug.cgi?id=144716
</del><ins>+                            [WK2][Fullscreen] Fullscreen video does not enter low-power mode.
+                            https://bugs.webkit.org/show_bug.cgi?id=144744
</ins><span class="cx"> 
</span><span class="cx">                             Reviewed by Darin Adler.
</span><span class="cx"> 
</span><del>-                            We create a mask animation for the transition between windowed and fullscreen modes, on the
-                            assumption that the element being taken into fullscreen mode does not have visible children
-                            who extend beyond that elements bounds. This assumption breaks down in the case where div
-                            with absolutely positioned children is taken fullscreen. While we can't necessarily make the
-                            transition look correct in this case, we can remove the mask after the transition completes.
</del><ins>+                            One of the requirements of entering low-power compositing mode is that no masking layers
+                            are present in any of the ancestors of the fullscreen video layer. So once our fullscreen
+                            transition animation completes, remove the mask layer entirely from our clipping layer.
+                            This means it needs to be re-created and added when entering fullscreen, rather than just
+                            at initialization time.
</ins><span class="cx"> 
</span><span class="cx">                             * UIProcess/mac/WKFullScreenWindowController.mm:
</span><ins>+                            (-[WKFullScreenWindowController initWithWindow:webView:]):
</ins><span class="cx">                             (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
</span><del>-                            * WebProcess/MediaCache/WebMediaKeyStorageManager.cpp:
-                            (WebKit::removeAllMediaKeyStorageForOriginPath):
</del><ins>+                            (-[WKFullScreenWindowController _startEnterFullScreenAnimationWithDuration:]):
</ins><span class="cx"> 
</span><span class="cx">                     2015-05-12  Dana Burkart
</span><span class="cx">                     Dana Burkart  &lt;dburkart@apple.com
</span><span class="cx">                     dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                            Merge r183909. rdar://problem/18894598
</del><ins>+                            Merge r183911. rdar://problem/20702435
</ins><span class="cx"> 
</span><del>-                        2015-05-06  Daniel Bates  &lt;dabates@apple.com&gt;
</del><ins>+                        2015-05-06  Jer Noble  &lt;jer.noble@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                [iOS][WK2] Pause/resume database thread when UIProcess enters/leaves the background
-                                https://bugs.webkit.org/show_bug.cgi?id=144657
-                                &lt;rdar://problem/18894598&gt;
</del><ins>+                                [WK2][Fullscreen] Elements whose children extend beyond their bounds are clipped in fullscreen mode.
+                                https://bugs.webkit.org/show_bug.cgi?id=144716
</ins><span class="cx"> 
</span><del>-                                Reviewed by Andy Estes.
</del><ins>+                                Reviewed by Darin Adler.
</ins><span class="cx"> 
</span><del>-                                Pause and resume the database thread when the UIProcess enters and leaves the background,
-                                respectively, so that we avoid WebProcess termination due to holding a locked SQLite
-                                database file when the WebProcess is suspended. This behavior matches the analagous
-                                behavior in Legacy WebKit.
</del><ins>+                                We create a mask animation for the transition between windowed and fullscreen modes, on the
+                                assumption that the element being taken into fullscreen mode does not have visible children
+                                who extend beyond that elements bounds. This assumption breaks down in the case where div
+                                with absolutely positioned children is taken fullscreen. While we can't necessarily make the
+                                transition look correct in this case, we can remove the mask after the transition completes.
</ins><span class="cx"> 
</span><del>-                                * UIProcess/WebPageProxy.h:
-                                * UIProcess/ios/WKContentView.mm:
-                                (-[WKContentView _applicationDidEnterBackground:]): Call WebPageProxy::applicationDidEnterBackground()
-                                when the UIProcess enters the background.
-                                * UIProcess/ios/WebPageProxyIOS.mm:
-                                (WebKit::WebPageProxy::applicationDidEnterBackground): Added; notify the WebProcess to pause the database thread.
-                                We temporarily take out background assertion on the WebProcess before sending this notification to ensure that the
-                                WebProcess is running to receive it. We'll release this assertion when the WebProcess replies that it received the
-                                notification.
-                                * WebProcess/WebCoreSupport/WebDatabaseManager.cpp:
-                                (WebKit::WebDatabaseManager::setPauseAllDatabases): Added; turns around and calls DatabaseManager::setPauseAllDatabases().
-                                * WebProcess/WebCoreSupport/WebDatabaseManager.h:
-                                * WebProcess/WebPage/WebPage.h:
-                                * WebProcess/WebPage/WebPage.messages.in: Add message ApplicationDidEnterBackground(). Also,
-                                add empty lines to help demarcate this message and the other UIKit application lifecycle-related
-                                messages from the rest of the list of messages.
-                                * WebProcess/WebPage/ios/WebPageIOS.mm:
-                                (WebKit::WebPage::applicationWillEnterForeground): Resume the database thread.
-                                (WebKit::WebPage::applicationDidEnterBackground): Pause the database thread.
</del><ins>+                                * UIProcess/mac/WKFullScreenWindowController.mm:
+                                (-[WKFullScreenWindowController finishedEnterFullScreenAnimation:]):
+                                * WebProcess/MediaCache/WebMediaKeyStorageManager.cpp:
+                                (WebKit::removeAllMediaKeyStorageForOriginPath):
</ins><span class="cx"> 
</span><span class="cx">                         2015-05-12  Dana Burkart
</span><del>-                        Dana Burkart  &lt;dburkart@apple.com&gt;
</del><ins>+                        Dana Burkart  &lt;dburkart@apple.com
+                        dburkart@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                Merge r183942. rdar://problem/20049088
</del><ins>+                                Merge r183909. rdar://problem/18894598
</ins><span class="cx"> 
</span><del>-                            2015-05-06  Dean Jackson  &lt;dino@apple.com&gt;
</del><ins>+                            2015-05-06  Daniel Bates  &lt;dabates@apple.com&gt;
</ins><span class="cx"> 
</span><del>-                                    Handle backdrop views that have to tile
-                                    https://bugs.webkit.org/show_bug.cgi?id=142317
-                                    &lt;rdar://problem/20049088&gt;
</del><ins>+                                    [iOS][WK2] Pause/resume database thread when UIProcess enters/leaves the background
+                                    https://bugs.webkit.org/show_bug.cgi?id=144657
+                                    &lt;rdar://problem/18894598&gt;
</ins><span class="cx"> 
</span><del>-                                    Reviewed by Simon Fraser.
</del><ins>+                                    Reviewed by Andy Estes.
</ins><span class="cx"> 
</span><del>-                                    Take 2 - this was rolled out because Mavericks was crashing.
</del><ins>+                                    Pause and resume the database thread when the UIProcess enters and leaves the background,
+                                    respectively, so that we avoid WebProcess termination due to holding a locked SQLite
+                                    database file when the WebProcess is suspended. This behavior matches the analagous
+                                    behavior in Legacy WebKit.
</ins><span class="cx"> 
</span><del>-                                    Add some better logging for custom appearance.
</del><ins>+                                    * UIProcess/WebPageProxy.h:
+                                    * UIProcess/ios/WKContentView.mm:
+                                    (-[WKContentView _applicationDidEnterBackground:]): Call WebPageProxy::applicationDidEnterBackground()
+                                    when the UIProcess enters the background.
+                                    * UIProcess/ios/WebPageProxyIOS.mm:
+                                    (WebKit::WebPageProxy::applicationDidEnterBackground): Added; notify the WebProcess to pause the database thread.
+                                    We temporarily take out background assertion on the WebProcess before sending this notification to ensure that the
+                                    WebProcess is running to receive it. We'll release this assertion when the WebProcess replies that it received the
+                                    notification.
+                                    * WebProcess/WebCoreSupport/WebDatabaseManager.cpp:
+                                    (WebKit::WebDatabaseManager::setPauseAllDatabases): Added; turns around and calls DatabaseManager::setPauseAllDatabases().
+                                    * WebProcess/WebCoreSupport/WebDatabaseManager.h:
+                                    * WebProcess/WebPage/WebPage.h:
+                                    * WebProcess/WebPage/WebPage.messages.in: Add message ApplicationDidEnterBackground(). Also,
+                                    add empty lines to help demarcate this message and the other UIKit application lifecycle-related
+                                    messages from the rest of the list of messages.
+                                    * WebProcess/WebPage/ios/WebPageIOS.mm:
+                                    (WebKit::WebPage::applicationWillEnterForeground): Resume the database thread.
+                                    (WebKit::WebPage::applicationDidEnterBackground): Pause the database thread.
</ins><span class="cx"> 
</span><del>-                                    * Shared/mac/RemoteLayerTreeTransaction.mm:
-                                    (WebKit::RemoteLayerTreeTextStream::operator&lt;&lt;):
-
</del><span class="cx">                             2015-05-12  Dana Burkart
</span><span class="cx">                             Dana Burkart  &lt;dburkart@apple.com&gt;
</span><span class="cx"> 
</span><del>-                                    Merge r183894. rdar://problem/20049088
</del><ins>+                                    Merge r183942. rdar://problem/20049088
</ins><span class="cx"> 
</span><span class="cx">                                 2015-05-06  Dean Jackson  &lt;dino@apple.com&gt;
</span><span class="cx"> 
</span><span class="lines">@@ -193,11 +192,31 @@
</span><span class="cx"> 
</span><span class="cx">                                         Reviewed by Simon Fraser.
</span><span class="cx"> 
</span><ins>+                                        Take 2 - this was rolled out because Mavericks was crashing.
+
</ins><span class="cx">                                         Add some better logging for custom appearance.
</span><span class="cx"> 
</span><span class="cx">                                         * Shared/mac/RemoteLayerTreeTransaction.mm:
</span><span class="cx">                                         (WebKit::RemoteLayerTreeTextStream::operator&lt;&lt;):
</span><span class="cx"> 
</span><ins>+                                2015-05-12  Dana Burkart
+                                Dana Burkart  &lt;dburkart@apple.com&gt;
+
+                                        Merge r183894. rdar://problem/20049088
+
+                                    2015-05-06  Dean Jackson  &lt;dino@apple.com&gt;
+
+                                            Handle backdrop views that have to tile
+                                            https://bugs.webkit.org/show_bug.cgi?id=142317
+                                            &lt;rdar://problem/20049088&gt;
+
+                                            Reviewed by Simon Fraser.
+
+                                            Add some better logging for custom appearance.
+
+                                            * Shared/mac/RemoteLayerTreeTransaction.mm:
+                                            (WebKit::RemoteLayerTreeTextStream::operator&lt;&lt;):
+
</ins><span class="cx"> 2015-05-11  Babak Shafiei  &lt;bshafiei@apple.com&gt;
</span><span class="cx"> 
</span><span class="cx">         Merge r184004.
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebKit2UIProcessScrollingiosScrollingTreeOverflowScrollingNodeIOSmm"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/Scrolling/ios/ScrollingTreeOverflowScrollingNodeIOS.mm        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -80,10 +80,11 @@
</span><span class="cx"> #if ENABLE(CSS_SCROLL_SNAP)
</span><span class="cx"> - (void)scrollViewWillEndDragging:(UIScrollView *)scrollView withVelocity:(CGPoint)velocity targetContentOffset:(inout CGPoint *)targetContentOffset
</span><span class="cx"> {
</span><ins>+    unsigned ignore;
</ins><span class="cx">     if (!_scrollingTreeNode-&gt;horizontalSnapOffsets().isEmpty())
</span><del>-        targetContentOffset-&gt;x = closestSnapOffset&lt;float, CGFloat&gt;(_scrollingTreeNode-&gt;horizontalSnapOffsets(), targetContentOffset-&gt;x, velocity.x);
</del><ins>+        targetContentOffset-&gt;x = closestSnapOffset&lt;float, CGFloat&gt;(_scrollingTreeNode-&gt;horizontalSnapOffsets(), targetContentOffset-&gt;x, velocity.x, ignore);
</ins><span class="cx">     if (!_scrollingTreeNode-&gt;verticalSnapOffsets().isEmpty())
</span><del>-        targetContentOffset-&gt;y = closestSnapOffset&lt;float, CGFloat&gt;(_scrollingTreeNode-&gt;verticalSnapOffsets(), targetContentOffset-&gt;y, velocity.y);
</del><ins>+        targetContentOffset-&gt;y = closestSnapOffset&lt;float, CGFloat&gt;(_scrollingTreeNode-&gt;verticalSnapOffsets(), targetContentOffset-&gt;y, velocity.y, ignore);
</ins><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx"> 
</span></span></pre></div>
<a id="branchessafari601132branchSourceWebKit2UIProcessiosRemoteScrollingCoordinatorProxyIOSmm"></a>
<div class="modfile"><h4>Modified: branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm (184264 => 184265)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm        2015-05-13 05:33:16 UTC (rev 184264)
+++ branches/safari-601.1.32-branch/Source/WebKit2/UIProcess/ios/RemoteScrollingCoordinatorProxyIOS.mm        2015-05-13 05:33:23 UTC (rev 184265)
</span><span class="lines">@@ -150,8 +150,9 @@
</span><span class="cx">     ScrollingTreeFrameScrollingNode* rootFrame = static_cast&lt;ScrollingTreeFrameScrollingNode*&gt;(root);
</span><span class="cx">     const Vector&lt;float&gt;&amp; snapOffsets = axis == ScrollEventAxis::Horizontal ? rootFrame-&gt;horizontalSnapOffsets() : rootFrame-&gt;verticalSnapOffsets();
</span><span class="cx"> 
</span><ins>+    unsigned ignore = 0;
</ins><span class="cx">     float scaledScrollDestination = scrollDestination / m_webPageProxy.displayedContentScale();
</span><del>-    float rawClosestSnapOffset = closestSnapOffset&lt;float, float&gt;(snapOffsets, scaledScrollDestination, velocity);
</del><ins>+    float rawClosestSnapOffset = closestSnapOffset&lt;float, float&gt;(snapOffsets, scaledScrollDestination, velocity, ignore);
</ins><span class="cx">     return rawClosestSnapOffset * m_webPageProxy.displayedContentScale();
</span><span class="cx"> }
</span><span class="cx"> #endif
</span></span></pre>
</div>
</div>

</body>
</html>