Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(858)

Unified Diff: Source/core/layout/compositing/CompositingLayerAssigner.cpp

Issue 1162383003: C++11: Replace 0 with nullptr where applicable in layout code. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add one more file. Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/layout/compositing/CompositingLayerAssigner.cpp
diff --git a/Source/core/layout/compositing/CompositingLayerAssigner.cpp b/Source/core/layout/compositing/CompositingLayerAssigner.cpp
index d851ce512e9c100b6c158adbe5e8969c86c5ffb1..ebbe2e4d60c3b8a5107543d89478c8395bf45a1b 100644
--- a/Source/core/layout/compositing/CompositingLayerAssigner.cpp
+++ b/Source/core/layout/compositing/CompositingLayerAssigner.cpp
@@ -210,7 +210,7 @@ void CompositingLayerAssigner::updateSquashingAssignment(DeprecatedPaintLayer* l
// Before removing |layer| from an already-existing squashing layer that may have other content, issue a paint invalidation.
m_compositor->paintInvalidationOnCompositingChange(layer);
layer->groupedMapping()->setNeedsGraphicsLayerUpdate(GraphicsLayerUpdateSubtree);
- layer->setGroupedMapping(0);
+ layer->setGroupedMapping(nullptr);
}
// If we need to issue paint invalidations, do so now that we've removed it from a squashed layer.
@@ -241,10 +241,7 @@ void CompositingLayerAssigner::assignLayersToBackingsForReflectionLayer(Deprecat
static ScrollingCoordinator* scrollingCoordinatorFromLayer(DeprecatedPaintLayer& layer)
{
Page* page = layer.layoutObject()->frame()->page();
- if (!page)
- return 0;
-
- return page->scrollingCoordinator();
+ return (!page) ? nullptr : page->scrollingCoordinator();
}
void CompositingLayerAssigner::assignLayersToBackingsInternal(DeprecatedPaintLayer* layer, SquashingState& squashingState, Vector<DeprecatedPaintLayer*>& layersNeedingPaintInvalidation)
@@ -298,7 +295,7 @@ void CompositingLayerAssigner::assignLayersToBackingsInternal(DeprecatedPaintLay
layer->scrollParent()->scrollableArea()->setTopmostScrollChild(layer);
if (layer->needsCompositedScrolling())
- layer->scrollableArea()->setTopmostScrollChild(0);
+ layer->scrollableArea()->setTopmostScrollChild(nullptr);
DeprecatedPaintLayerStackingNodeIterator iterator(*layer->stackingNode(), NormalFlowChildren | PositiveZOrderChildren);
while (DeprecatedPaintLayerStackingNode* curNode = iterator.next())

Powered by Google App Engine
This is Rietveld 408576698