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

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

Issue 2593633002: Need to be inside the flow thread before converting a visual point. (Closed)
Patch Set: Created 4 years 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/core/layout/MapCoordinatesTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/LayoutObject.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutObject.cpp b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
index 0c01284265ff25a16cce08274ab9fd881c03666b..7e6d1b82393cf2d57d21de1177ea35bd69aca50a 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -2164,15 +2164,6 @@ void LayoutObject::mapAncestorToLocal(const LayoutBoxModelObject* ancestor,
container->mapAncestorToLocal(ancestor, transformState, mode);
LayoutSize containerOffset = offsetFromContainer(container);
- if (isLayoutFlowThread()) {
- // Descending into a flow thread. Convert to the local coordinate space,
- // i.e. flow thread coordinates.
- LayoutPoint visualPoint = LayoutPoint(transformState.mappedPoint());
- transformState.move(
- visualPoint -
- toLayoutFlowThread(this)->visualPointToFlowThreadPoint(visualPoint));
- }
-
bool preserve3D =
mode & UseTransforms &&
(container->style()->preserves3D() || style()->preserves3D());
@@ -2188,6 +2179,15 @@ void LayoutObject::mapAncestorToLocal(const LayoutBoxModelObject* ancestor,
: TransformState::FlattenTransform);
}
+ if (isLayoutFlowThread()) {
+ // Descending into a flow thread. Convert to the local coordinate space,
+ // i.e. flow thread coordinates.
+ LayoutPoint visualPoint = LayoutPoint(transformState.mappedPoint());
+ transformState.move(
+ visualPoint -
+ toLayoutFlowThread(this)->visualPointToFlowThreadPoint(visualPoint));
+ }
+
if (applyContainerFlip) {
IntPoint centerPoint = roundedIntPoint(transformState.mappedPoint());
transformState.move(
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/MapCoordinatesTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698