<!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>[182107] trunk/Source/WebCore</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/182107">182107</a></dd>
<dt>Author</dt> <dd>simon.fraser@apple.com</dd>
<dt>Date</dt> <dd>2015-03-27 22:45:20 -0700 (Fri, 27 Mar 2015)</dd>
</dl>
<h3>Log Message</h3>
<pre>nullptr cleanup in RenderLayer
https://bugs.webkit.org/show_bug.cgi?id=143174
Reviewed by Ryosuke Niwa.
Replace 0 with nullptr in RenderLayer.cpp.
* rendering/RenderLayer.cpp:
(WebCore::RenderLayer::filterRenderer):
(WebCore::RenderLayer::updateLayerPositionsAfterLayout):
(WebCore::RenderLayer::updateLayerPositionsAfterOverflowScroll):
(WebCore::RenderLayer::positionNewlyCreatedOverflowControls):
(WebCore::RenderLayer::enclosingOverflowClipLayer):
(WebCore::RenderLayer::enclosingCompositingLayer):
(WebCore::RenderLayer::enclosingCompositingLayerForRepaint):
(WebCore::RenderLayer::enclosingFilterLayer):
(WebCore::RenderLayer::enclosingFilterRepaintLayer):
(WebCore::RenderLayer::clippingRootForPainting):
(WebCore::RenderLayer::transparentPaintingAncestor):
(WebCore::transparencyClipBox):
(WebCore::RenderLayer::removeChild):
(WebCore::RenderLayer::removeOnlyThisLayer):
(WebCore::RenderLayer::insertOnlyThisLayer):
(WebCore::accumulateOffsetTowardsAncestor):
(WebCore::RenderLayer::enclosingScrollableArea):
(WebCore::RenderLayer::enclosingPaginationLayerInSubtree):
(WebCore::RenderLayer::enclosingElement):
(WebCore::RenderLayer::enclosingFlowThreadAncestor):
(WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
(WebCore::RenderLayer::hitTestLayer):
(WebCore::RenderLayer::hitTestTransformedLayerInFragments):
(WebCore::RenderLayer::hitTestLayerByApplyingTransform):
(WebCore::RenderLayer::hitTestList):
(WebCore::RenderLayer::updateClipRects):
(WebCore::RenderLayer::clipRects):
(WebCore::RenderLayer::calculateClipRects):</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCorerenderingRenderLayercpp">trunk/Source/WebCore/rendering/RenderLayer.cpp</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (182106 => 182107)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2015-03-28 05:04:23 UTC (rev 182106)
+++ trunk/Source/WebCore/ChangeLog        2015-03-28 05:45:20 UTC (rev 182107)
</span><span class="lines">@@ -1,3 +1,42 @@
</span><ins>+2015-03-27 Simon Fraser <simon.fraser@apple.com>
+
+ nullptr cleanup in RenderLayer
+ https://bugs.webkit.org/show_bug.cgi?id=143174
+
+ Reviewed by Ryosuke Niwa.
+
+ Replace 0 with nullptr in RenderLayer.cpp.
+
+ * rendering/RenderLayer.cpp:
+ (WebCore::RenderLayer::filterRenderer):
+ (WebCore::RenderLayer::updateLayerPositionsAfterLayout):
+ (WebCore::RenderLayer::updateLayerPositionsAfterOverflowScroll):
+ (WebCore::RenderLayer::positionNewlyCreatedOverflowControls):
+ (WebCore::RenderLayer::enclosingOverflowClipLayer):
+ (WebCore::RenderLayer::enclosingCompositingLayer):
+ (WebCore::RenderLayer::enclosingCompositingLayerForRepaint):
+ (WebCore::RenderLayer::enclosingFilterLayer):
+ (WebCore::RenderLayer::enclosingFilterRepaintLayer):
+ (WebCore::RenderLayer::clippingRootForPainting):
+ (WebCore::RenderLayer::transparentPaintingAncestor):
+ (WebCore::transparencyClipBox):
+ (WebCore::RenderLayer::removeChild):
+ (WebCore::RenderLayer::removeOnlyThisLayer):
+ (WebCore::RenderLayer::insertOnlyThisLayer):
+ (WebCore::accumulateOffsetTowardsAncestor):
+ (WebCore::RenderLayer::enclosingScrollableArea):
+ (WebCore::RenderLayer::enclosingPaginationLayerInSubtree):
+ (WebCore::RenderLayer::enclosingElement):
+ (WebCore::RenderLayer::enclosingFlowThreadAncestor):
+ (WebCore::RenderLayer::hitTestFixedLayersInNamedFlows):
+ (WebCore::RenderLayer::hitTestLayer):
+ (WebCore::RenderLayer::hitTestTransformedLayerInFragments):
+ (WebCore::RenderLayer::hitTestLayerByApplyingTransform):
+ (WebCore::RenderLayer::hitTestList):
+ (WebCore::RenderLayer::updateClipRects):
+ (WebCore::RenderLayer::clipRects):
+ (WebCore::RenderLayer::calculateClipRects):
+
</ins><span class="cx"> 2015-03-27 Gwang Yoon Hwang <yoon@igalia.com>
</span><span class="cx">
</span><span class="cx"> [TexMap] Seperate BitmapTexture related classes implementations from TextureMapper
</span></span></pre></div>
<a id="trunkSourceWebCorerenderingRenderLayercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/rendering/RenderLayer.cpp (182106 => 182107)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/rendering/RenderLayer.cpp        2015-03-28 05:04:23 UTC (rev 182106)
+++ trunk/Source/WebCore/rendering/RenderLayer.cpp        2015-03-28 05:45:20 UTC (rev 182107)
</span><span class="lines">@@ -451,14 +451,14 @@
</span><span class="cx"> FilterEffectRenderer* RenderLayer::filterRenderer() const
</span><span class="cx"> {
</span><span class="cx"> FilterInfo* filterInfo = FilterInfo::getIfExists(*this);
</span><del>- return filterInfo ? filterInfo->renderer() : 0;
</del><ins>+ return filterInfo ? filterInfo->renderer() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderLayer::updateLayerPositionsAfterLayout(const RenderLayer* rootLayer, UpdateLayerPositionsFlags flags)
</span><span class="cx"> {
</span><span class="cx"> RenderGeometryMap geometryMap(UseTransforms);
</span><span class="cx"> if (this != rootLayer)
</span><del>- geometryMap.pushMappingsToAncestor(parent(), 0);
</del><ins>+ geometryMap.pushMappingsToAncestor(parent(), nullptr);
</ins><span class="cx"> updateLayerPositions(&geometryMap, flags);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -816,7 +816,7 @@
</span><span class="cx"> {
</span><span class="cx"> RenderGeometryMap geometryMap(UseTransforms);
</span><span class="cx"> if (this != renderer().view().layer())
</span><del>- geometryMap.pushMappingsToAncestor(parent(), 0);
</del><ins>+ geometryMap.pushMappingsToAncestor(parent(), nullptr);
</ins><span class="cx">
</span><span class="cx"> // FIXME: why is it OK to not check the ancestors of this layer in order to
</span><span class="cx"> // initialize the HasSeenViewportConstrainedAncestor and HasSeenAncestorWithOverflowClip flags?
</span><span class="lines">@@ -886,7 +886,7 @@
</span><span class="cx">
</span><span class="cx"> RenderGeometryMap geometryMap(UseTransforms);
</span><span class="cx"> if (this != renderer().view().layer() && parent())
</span><del>- geometryMap.pushMappingsToAncestor(parent(), 0);
</del><ins>+ geometryMap.pushMappingsToAncestor(parent(), nullptr);
</ins><span class="cx">
</span><span class="cx"> LayoutPoint offsetFromRoot = LayoutPoint(geometryMap.absolutePoint(FloatPoint()));
</span><span class="cx"> positionOverflowControls(toIntSize(roundedIntPoint(offsetFromRoot)));
</span><span class="lines">@@ -1016,7 +1016,7 @@
</span><span class="cx">
</span><span class="cx"> layer = layer->parent();
</span><span class="cx"> }
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // FIXME: This is terrible. Bring back a cached bit for this someday. This crawl is going to slow down all
</span><span class="lines">@@ -1541,7 +1541,7 @@
</span><span class="cx"> return const_cast<RenderLayer*>(curr);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderLayer::enclosingCompositingLayerForRepaint(IncludeSelfOrNot includeSelf) const
</span><span class="lines">@@ -1554,7 +1554,7 @@
</span><span class="cx"> return const_cast<RenderLayer*>(curr);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderLayer::enclosingFilterLayer(IncludeSelfOrNot includeSelf) const
</span><span class="lines">@@ -1565,7 +1565,7 @@
</span><span class="cx"> return const_cast<RenderLayer*>(curr);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderLayer::enclosingFilterRepaintLayer() const
</span><span class="lines">@@ -1574,7 +1574,7 @@
</span><span class="cx"> if ((curr != this && curr->requiresFullLayerImageForFilters()) || compositedWithOwnBackingStore(curr) || curr->isRootLayer())
</span><span class="cx"> return const_cast<RenderLayer*>(curr);
</span><span class="cx"> }
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderLayer::setFilterBackendNeedsRepaintingInRect(const LayoutRect& rect)
</span><span class="lines">@@ -1642,7 +1642,7 @@
</span><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> LayoutPoint RenderLayer::absoluteToContents(const LayoutPoint& absolutePoint) const
</span><span class="lines">@@ -1663,15 +1663,15 @@
</span><span class="cx"> RenderLayer* RenderLayer::transparentPaintingAncestor()
</span><span class="cx"> {
</span><span class="cx"> if (isComposited())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> for (RenderLayer* curr = parent(); curr; curr = curr->parent()) {
</span><span class="cx"> if (curr->isComposited())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> if (curr->isTransparent())
</span><span class="cx"> return curr;
</span><span class="cx"> }
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> enum TransparencyClipBoxBehavior {
</span><span class="lines">@@ -1744,7 +1744,7 @@
</span><span class="cx"> // The best we can do here is to use enclosed bounding boxes to establish a "fuzzy" enough clip to encompass
</span><span class="cx"> // the transformed layer and all of its children.
</span><span class="cx"> RenderLayer::PaginationInclusionMode mode = transparencyBehavior == HitTestingTransparencyClipBox ? RenderLayer::IncludeCompositedPaginatedLayers : RenderLayer::ExcludeCompositedPaginatedLayers;
</span><del>- const RenderLayer* paginationLayer = transparencyMode == DescendantsOfTransparencyClipBox ? layer.enclosingPaginationLayer(mode) : 0;
</del><ins>+ const RenderLayer* paginationLayer = transparencyMode == DescendantsOfTransparencyClipBox ? layer.enclosingPaginationLayer(mode) : nullptr;
</ins><span class="cx"> const RenderLayer* rootLayerForTransform = paginationLayer ? paginationLayer : rootLayer;
</span><span class="cx"> LayoutSize delta = layer.offsetFromAncestor(rootLayerForTransform);
</span><span class="cx">
</span><span class="lines">@@ -1901,9 +1901,9 @@
</span><span class="cx"> if (oldChild->renderer().isOutOfFlowPositioned() || oldChild->hasOutOfFlowPositionedDescendant())
</span><span class="cx"> dirtyAncestorChainHasOutOfFlowPositionedDescendantStatus();
</span><span class="cx">
</span><del>- oldChild->setPreviousSibling(0);
- oldChild->setNextSibling(0);
- oldChild->setParent(0);
</del><ins>+ oldChild->setPreviousSibling(nullptr);
+ oldChild->setNextSibling(nullptr);
+ oldChild->setParent(nullptr);
</ins><span class="cx">
</span><span class="cx"> oldChild->updateDescendantDependentFlags();
</span><span class="cx"> if (oldChild->m_hasVisibleContent || oldChild->m_hasVisibleDescendant)
</span><span class="lines">@@ -1950,7 +1950,7 @@
</span><span class="cx"> current->setRepaintStatus(NeedsFullRepaint);
</span><span class="cx"> // updateLayerPositions depends on hasLayer() already being false for proper layout.
</span><span class="cx"> ASSERT(!renderer().hasLayer());
</span><del>- current->updateLayerPositions(0); // FIXME: use geometry map.
</del><ins>+ current->updateLayerPositions(); // FIXME: use geometry map.
</ins><span class="cx"> current = next;
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1966,7 +1966,7 @@
</span><span class="cx"> // Find our enclosingLayer and add ourselves.
</span><span class="cx"> RenderLayer* parentLayer = renderer().parent()->enclosingLayer();
</span><span class="cx"> ASSERT(parentLayer);
</span><del>- RenderLayer* beforeChild = parentLayer->reflectionLayer() != this ? renderer().parent()->findNextLayer(parentLayer, &renderer()) : 0;
</del><ins>+ RenderLayer* beforeChild = parentLayer->reflectionLayer() != this ? renderer().parent()->findNextLayer(parentLayer, &renderer()) : nullptr;
</ins><span class="cx"> parentLayer->addChild(this, beforeChild);
</span><span class="cx"> }
</span><span class="cx">
</span><span class="lines">@@ -1993,7 +1993,7 @@
</span><span class="cx"> EPosition position = renderer.style().position();
</span><span class="cx">
</span><span class="cx"> // FIXME: Special casing RenderFlowThread so much for fixed positioning here is not great.
</span><del>- RenderFlowThread* fixedFlowThreadContainer = position == FixedPosition ? renderer.flowThreadContainingBlock() : 0;
</del><ins>+ RenderFlowThread* fixedFlowThreadContainer = position == FixedPosition ? renderer.flowThreadContainingBlock() : nullptr;
</ins><span class="cx"> if (fixedFlowThreadContainer && !fixedFlowThreadContainer->isOutOfFlowPositioned())
</span><span class="cx"> fixedFlowThreadContainer = nullptr;
</span><span class="cx">
</span><span class="lines">@@ -2096,7 +2096,7 @@
</span><span class="cx"> parentLayer = layer->parent();
</span><span class="cx">
</span><span class="cx"> if (!parentLayer)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> location += toLayoutSize(layer->location());
</span><span class="cx">
</span><span class="lines">@@ -3163,7 +3163,7 @@
</span><span class="cx">
</span><span class="cx"> // FIXME: We should return the frame view here (or possibly an ancestor frame view,
</span><span class="cx"> // if the frame view isn't scrollable.
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool RenderLayer::isScrollableOrRubberbandable()
</span><span class="lines">@@ -4417,11 +4417,11 @@
</span><span class="cx"> return paginationLayer;
</span><span class="cx">
</span><span class="cx"> // Walk up the layer tree and see which layer we hit first. If it's the root, then the enclosing pagination
</span><del>- // layer isn't in our subtree and we return 0. If we hit the enclosing pagination layer first, then
</del><ins>+ // layer isn't in our subtree and we return nullptr. If we hit the enclosing pagination layer first, then
</ins><span class="cx"> // we can return it.
</span><span class="cx"> for (const RenderLayer* layer = this; layer; layer = layer->parent()) {
</span><span class="cx"> if (layer == rootLayer)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> if (layer == paginationLayer)
</span><span class="cx"> return paginationLayer;
</span><span class="cx"> }
</span><span class="lines">@@ -4429,7 +4429,7 @@
</span><span class="cx"> // This should never be reached, since an enclosing layer should always either be the rootLayer or be
</span><span class="cx"> // our enclosing pagination layer.
</span><span class="cx"> ASSERT_NOT_REACHED();
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderLayer::collectFragments(LayerFragments& fragments, const RenderLayer* rootLayer, const LayoutRect& dirtyRect, PaginationInclusionMode inclusionMode,
</span><span class="lines">@@ -4825,7 +4825,7 @@
</span><span class="cx"> if (Element* e = r->element())
</span><span class="cx"> return e;
</span><span class="cx"> }
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderLayer::enclosingFlowThreadAncestor() const
</span><span class="lines">@@ -4834,7 +4834,7 @@
</span><span class="cx"> for (; curr && !curr->isRenderFlowThread(); curr = curr->parent()) {
</span><span class="cx"> if (curr->isStackingContainer() && curr->isComposited()) {
</span><span class="cx"> // We only adjust the position of the first level of layers.
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx"> }
</span><span class="cx"> return curr;
</span><span class="lines">@@ -4932,11 +4932,11 @@
</span><span class="cx"> bool depthSortDescendants)
</span><span class="cx"> {
</span><span class="cx"> if (!isRootLayer())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> // Get the named flows for the view
</span><span class="cx"> if (!renderer().view().hasRenderNamedFlowThreads())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> Vector<RenderLayer*> fixedLayers;
</span><span class="cx"> renderer().view().flowThreadController().collectFixedPositionedLayers(fixedLayers);
</span><span class="lines">@@ -4980,13 +4980,13 @@
</span><span class="cx"> const HitTestingTransformState* transformState, double* zOffset)
</span><span class="cx"> {
</span><span class="cx"> if (!isSelfPaintingLayer() && !hasSelfPaintingLayerDescendant())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> RenderNamedFlowFragment* namedFlowFragment = currentRenderNamedFlowFragment();
</span><span class="cx">
</span><span class="cx"> // Prevent hitting the fixed layers inside the flow thread when hitting through regions.
</span><span class="cx"> if (renderer().fixedPositionedWithNamedFlowContainingBlock() && namedFlowFragment)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> // Don't hit-test the layer if the renderer doesn't belong to this region.
</span><span class="cx"> // This is true as long as we clamp the range of a box to its containing block range.
</span><span class="lines">@@ -4995,7 +4995,7 @@
</span><span class="cx"> ASSERT(namedFlowFragment->isValid());
</span><span class="cx"> RenderFlowThread* flowThread = namedFlowFragment->flowThread();
</span><span class="cx"> if (!flowThread->objectShouldFragmentInFlowRegion(&renderer(), namedFlowFragment))
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> // The natural thing would be to keep HitTestingTransformState on the stack, but it's big, so we heap-allocate.
</span><span class="lines">@@ -5011,7 +5011,7 @@
</span><span class="cx"> ClipRect clipRect = backgroundClipRect(clipRectsContext);
</span><span class="cx"> // Go ahead and test the enclosing clip now.
</span><span class="cx"> if (!clipRect.intersects(hitTestLocation))
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> return hitTestLayerByApplyingTransform(rootLayer, containerLayer, request, result, hitTestRect, hitTestLocation, transformState, zOffset);
</span><span class="lines">@@ -5036,7 +5036,7 @@
</span><span class="cx"> TransformationMatrix invertedMatrix = localTransformState->m_accumulatedTransform.inverse();
</span><span class="cx"> // If the z-vector of the matrix is negative, the back is facing towards the viewer.
</span><span class="cx"> if (invertedMatrix.m33() < 0)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RefPtr<HitTestingTransformState> unflattenedTransformState = localTransformState;
</span><span class="lines">@@ -5161,7 +5161,7 @@
</span><span class="cx"> result.append(tempResult);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool RenderLayer::hitTestContentsForFragments(const LayerFragments& layerFragments, const HitTestRequest& request, HitTestResult& result,
</span><span class="lines">@@ -5233,7 +5233,7 @@
</span><span class="cx"> return hitLayer;
</span><span class="cx"> }
</span><span class="cx">
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderLayer::hitTestLayerByApplyingTransform(RenderLayer* rootLayer, RenderLayer* containerLayer, const HitTestRequest& request, HitTestResult& result,
</span><span class="lines">@@ -5245,7 +5245,7 @@
</span><span class="cx">
</span><span class="cx"> // If the transform can't be inverted, then don't hit test this layer at all.
</span><span class="cx"> if (!newTransformState->m_accumulatedTransform.isInvertible())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> // Compute the point and the hit test rect in the coords of this layer by using the values
</span><span class="cx"> // from the transformState, which store the point and quad in the coords of the last flattened
</span><span class="lines">@@ -5308,10 +5308,10 @@
</span><span class="cx"> bool depthSortDescendants)
</span><span class="cx"> {
</span><span class="cx"> if (!list)
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> if (!hasSelfPaintingLayerDescendant())
</span><del>- return 0;
</del><ins>+ return nullptr;
</ins><span class="cx">
</span><span class="cx"> RenderLayer* resultLayer = nullptr;
</span><span class="cx"> for (int i = list->size() - 1; i >= 0; --i) {
</span><span class="lines">@@ -5360,7 +5360,7 @@
</span><span class="cx">
</span><span class="cx"> // For transformed layers, the root layer was shifted to be us, so there is no need to
</span><span class="cx"> // examine the parent. We want to cache clip rects with us as the root.
</span><del>- RenderLayer* parentLayer = clipRectsContext.rootLayer != this ? parent() : 0;
</del><ins>+ RenderLayer* parentLayer = clipRectsContext.rootLayer != this ? parent() : nullptr;
</ins><span class="cx"> if (parentLayer)
</span><span class="cx"> parentLayer->updateClipRects(clipRectsContext);
</span><span class="cx">
</span><span class="lines">@@ -5416,7 +5416,7 @@
</span><span class="cx"> ClipRects* RenderLayer::clipRects(const ClipRectsContext& context) const
</span><span class="cx"> {
</span><span class="cx"> ASSERT(context.clipRectsType < NumCachedClipRectsTypes);
</span><del>- return m_clipRectsCache ? m_clipRectsCache->getClipRects(context.clipRectsType, context.respectOverflowClip).get() : 0;
</del><ins>+ return m_clipRectsCache ? m_clipRectsCache->getClipRects(context.clipRectsType, context.respectOverflowClip).get() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderLayer::calculateClipRects(const ClipRectsContext& clipRectsContext, ClipRects& clipRects) const
</span><span class="lines">@@ -5435,7 +5435,7 @@
</span><span class="cx">
</span><span class="cx"> // For transformed layers, the root layer was shifted to be us, so there is no need to
</span><span class="cx"> // examine the parent. We want to cache clip rects with us as the root.
</span><del>- RenderLayer* parentLayer = clipRectsContext.rootLayer != this ? parent() : 0;
</del><ins>+ RenderLayer* parentLayer = clipRectsContext.rootLayer != this ? parent() : nullptr;
</ins><span class="cx">
</span><span class="cx"> // Ensure that our parent's clip has been calculated so that we can examine the values.
</span><span class="cx"> if (parentLayer) {
</span><span class="lines">@@ -6046,22 +6046,22 @@
</span><span class="cx">
</span><span class="cx"> GraphicsLayer* RenderLayer::layerForScrolling() const
</span><span class="cx"> {
</span><del>- return m_backing ? m_backing->scrollingContentsLayer() : 0;
</del><ins>+ return m_backing ? m_backing->scrollingContentsLayer() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> GraphicsLayer* RenderLayer::layerForHorizontalScrollbar() const
</span><span class="cx"> {
</span><del>- return m_backing ? m_backing->layerForHorizontalScrollbar() : 0;
</del><ins>+ return m_backing ? m_backing->layerForHorizontalScrollbar() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> GraphicsLayer* RenderLayer::layerForVerticalScrollbar() const
</span><span class="cx"> {
</span><del>- return m_backing ? m_backing->layerForVerticalScrollbar() : 0;
</del><ins>+ return m_backing ? m_backing->layerForVerticalScrollbar() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> GraphicsLayer* RenderLayer::layerForScrollCorner() const
</span><span class="cx"> {
</span><del>- return m_backing ? m_backing->layerForScrollCorner() : 0;
</del><ins>+ return m_backing ? m_backing->layerForScrollCorner() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> bool RenderLayer::paintsWithTransform(PaintBehavior paintBehavior) const
</span><span class="lines">@@ -6759,7 +6759,7 @@
</span><span class="cx"> void RenderLayer::updateScrollCornerStyle()
</span><span class="cx"> {
</span><span class="cx"> RenderElement* actualRenderer = rendererForScrollbar(renderer());
</span><del>- RefPtr<RenderStyle> corner = renderer().hasOverflowClip() ? actualRenderer->getUncachedPseudoStyle(PseudoStyleRequest(SCROLLBAR_CORNER), &actualRenderer->style()) : PassRefPtr<RenderStyle>(0);
</del><ins>+ RefPtr<RenderStyle> corner = renderer().hasOverflowClip() ? actualRenderer->getUncachedPseudoStyle(PseudoStyleRequest(SCROLLBAR_CORNER), &actualRenderer->style()) : nullptr;
</ins><span class="cx">
</span><span class="cx"> if (!corner) {
</span><span class="cx"> m_scrollCorner = nullptr;
</span><span class="lines">@@ -6777,7 +6777,7 @@
</span><span class="cx"> void RenderLayer::updateResizerStyle()
</span><span class="cx"> {
</span><span class="cx"> RenderElement* actualRenderer = rendererForScrollbar(renderer());
</span><del>- RefPtr<RenderStyle> resizer = renderer().hasOverflowClip() ? actualRenderer->getUncachedPseudoStyle(PseudoStyleRequest(RESIZER), &actualRenderer->style()) : PassRefPtr<RenderStyle>(0);
</del><ins>+ RefPtr<RenderStyle> resizer = renderer().hasOverflowClip() ? actualRenderer->getUncachedPseudoStyle(PseudoStyleRequest(RESIZER), &actualRenderer->style()) : nullptr;
</ins><span class="cx">
</span><span class="cx"> if (!resizer) {
</span><span class="cx"> m_resizer = nullptr;
</span><span class="lines">@@ -6794,7 +6794,7 @@
</span><span class="cx">
</span><span class="cx"> RenderLayer* RenderLayer::reflectionLayer() const
</span><span class="cx"> {
</span><del>- return m_reflection ? m_reflection->layer() : 0;
</del><ins>+ return m_reflection ? m_reflection->layer() : nullptr;
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> void RenderLayer::createReflection()
</span><span class="lines">@@ -6810,7 +6810,7 @@
</span><span class="cx"> if (!m_reflection->documentBeingDestroyed())
</span><span class="cx"> m_reflection->removeLayers(this);
</span><span class="cx">
</span><del>- m_reflection->setParent(0);
</del><ins>+ m_reflection->setParent(nullptr);
</ins><span class="cx"> m_reflection = nullptr;
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>