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

Unified Diff: third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp

Issue 2150413002: Use node() when generating element id's (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 years, 5 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: third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp
diff --git a/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp b/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp
index 5255bb300d90dc11ced663264acbfcd9eec11f6b..f5b0d5cfca1e46479a4d7e8c45396cff5d7d16f7 100644
--- a/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp
+++ b/third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp
@@ -229,7 +229,7 @@ std::unique_ptr<GraphicsLayer> CompositedLayerMapping::createGraphicsLayer(Compo
graphicsLayer->setCompositingReasons(reasons);
graphicsLayer->setSquashingDisallowedReasons(squashingDisallowedReasons);
- if (Node* owningNode = m_owningLayer.layoutObject()->generatingNode())
+ if (Node* owningNode = m_owningLayer.layoutObject()->node())
graphicsLayer->setOwnerNodeId(DOMNodeIds::idForNode(owningNode));
return graphicsLayer;
@@ -1547,7 +1547,7 @@ void CompositedLayerMapping::updateElementIdAndCompositorMutableProperties()
uint32_t primaryMutableProperties = CompositorMutableProperty::kNone;
uint32_t scrollMutableProperties = CompositorMutableProperty::kNone;
- Node* owningNode = m_owningLayer.layoutObject()->generatingNode();
+ Node* owningNode = m_owningLayer.layoutObject()->node();
Element* owningElement = nullptr;
if (owningNode && owningNode->isElementNode())
owningElement = toElement(owningNode);
@@ -1661,7 +1661,7 @@ bool CompositedLayerMapping::updateScrollingLayers(bool needsScrollingLayers)
// Inner layer which renders the content that scrolls.
m_scrollingContentsLayer = createGraphicsLayer(CompositingReasonLayerForScrollingContents);
- if (Node* owningNode = m_owningLayer.layoutObject()->generatingNode()) {
+ if (Node* owningNode = m_owningLayer.layoutObject()->node()) {
m_scrollingContentsLayer->setElementId(createCompositorElementId(DOMNodeIds::idForNode(owningNode), CompositorSubElementId::Scroll));
m_scrollingContentsLayer->setCompositorMutableProperties(CompositorMutableProperty::kScrollLeft | CompositorMutableProperty::kScrollTop);
}

Powered by Google App Engine
This is Rietveld 408576698