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

Unified Diff: third_party/WebKit/Source/core/frame/VisualViewport.cpp

Issue 2443633002: Avoid element id collisions with the visual viewport (Closed)
Patch Set: fix typo. Created 4 years, 2 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/graphics/CompositorElementId.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/frame/VisualViewport.cpp
diff --git a/third_party/WebKit/Source/core/frame/VisualViewport.cpp b/third_party/WebKit/Source/core/frame/VisualViewport.cpp
index 61572c8f2ff53a1aec04dea03dc4032b8cd09927..c75ad1e66edb10b4ce1ead1bd5a75bc752191696 100644
--- a/third_party/WebKit/Source/core/frame/VisualViewport.cpp
+++ b/third_party/WebKit/Source/core/frame/VisualViewport.cpp
@@ -391,9 +391,10 @@ void VisualViewport::attachToLayerTree(GraphicsLayer* currentLayerTreeRoot) {
m_innerViewportContainerLayer->platformLayer());
m_innerViewportScrollLayer->platformLayer()->setUserScrollable(true, true);
if (mainFrame()) {
- if (Document* document = mainFrame()->document())
+ if (Document* document = mainFrame()->document()) {
m_innerViewportScrollLayer->setElementId(createCompositorElementId(
- DOMNodeIds::idForNode(document), CompositorSubElementId::Scroll));
+ DOMNodeIds::idForNode(document), CompositorSubElementId::Viewport));
+ }
}
m_rootTransformLayer->addChild(m_innerViewportContainerLayer.get());
« no previous file with comments | « no previous file | third_party/WebKit/Source/platform/graphics/CompositorElementId.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698