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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutView.cpp

Issue 2431473003: Intersection Observer support for OOPIF (Closed)
Patch Set: dcheng comments addressed Created 3 years, 11 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/LayoutView.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutView.cpp b/third_party/WebKit/Source/core/layout/LayoutView.cpp
index 269ad5bb07092e2f6d9ab4d97ddcf9000953944d..5fd34974ec2c21ebcb3ba5a9380956fe36b7f11e 100644
--- a/third_party/WebKit/Source/core/layout/LayoutView.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutView.cpp
@@ -343,6 +343,8 @@ void LayoutView::mapLocalToAncestor(const LayoutBoxModelObject* ancestor,
transformState.move(parentDocLayoutItem.contentBoxOffset());
parentDocLayoutItem.mapLocalToAncestor(ancestor, transformState, mode);
+ } else {
+ frameView()->applyTransformForTopFrameSpace(transformState);
}
}
}
@@ -463,16 +465,15 @@ bool LayoutView::mapToVisualRectInAncestorSpace(
rect.move(offsetForFixedPosition(true));
// Apply our transform if we have one (because of full page zooming).
- if (!ancestor && layer() && layer()->transform())
+ if (layer() && layer()->transform())
rect = layer()->transform()->mapRect(rect);
- ASSERT(ancestor);
if (ancestor == this)
return true;
Element* owner = document().localOwner();
if (!owner)
- return true;
+ return frameView()->mapToVisualRectInTopFrameSpace(rect);
if (LayoutBox* obj = owner->layoutBox()) {
if (!(mode & InputIsInFrameCoordinates)) {
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutView.h ('k') | third_party/WebKit/Source/web/RemoteFrameClientImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698