Chromium Code Reviews| 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 ac03b02a63fada3e05335e07899878a16129e44e..72497e2872c9b1e0c09d35061f55962307eec2c2 100644 |
| --- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp |
| +++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp |
| @@ -2076,6 +2076,13 @@ void LayoutObject::mapLocalToAncestor(const LayoutBoxModelObject* ancestor, |
| } |
| LayoutSize containerOffset = offsetFromContainer(container); |
| + |
| + // TODO(smcgruer): This is inefficient. Instead we should avoid including |
| + // offsetForInFlowPosition in offsetFromContainer when ignoring sticky. |
| + if (mode & IgnoreStickyOffset && isBoxModelObject() && isStickyPositioned()) { |
|
flackr
2017/02/24 15:07:37
I don't think the object can be sticky position an
smcgruer
2017/02/24 15:27:57
Done.
|
| + containerOffset -= toLayoutBoxModelObject(this)->offsetForInFlowPosition(); |
| + } |
| + |
| if (isLayoutFlowThread()) { |
| // So far the point has been in flow thread coordinates (i.e. as if |
| // everything in the fragmentation context lived in one tall single column). |