Chromium Code Reviews| Index: third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp |
| diff --git a/third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp b/third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp |
| index 562f5bb5d925ff0cf8a10835865133e3378b361a..2b4c6b5186c5d55ae2fa42585edcd96e356d3243 100644 |
| --- a/third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp |
| +++ b/third_party/WebKit/Source/core/layout/LayoutBoxModelObject.cpp |
| @@ -146,7 +146,7 @@ bool LayoutBoxModelObject::HasAcceleratedCompositing() const { |
| } |
| LayoutBoxModelObject::LayoutBoxModelObject(ContainerNode* node) |
| - : LayoutObject(node) {} |
| + : LayoutObject(node), is_in_sticky_subtree_(false) {} |
| bool LayoutBoxModelObject::UsesCompositedScrolling() const { |
| return HasOverflowClip() && HasLayer() && |
| @@ -477,6 +477,11 @@ void LayoutBoxModelObject::StyleDidChange(StyleDifference diff, |
| else |
| frame_view->RemoveViewportConstrainedObject(*this); |
| } |
| + |
| + is_in_sticky_subtree_ = |
| + new_style_is_sticky || |
| + (Parent() && Parent()->EnclosingBoxModelObject() && |
|
chrishtr
2017/04/20 17:40:34
Shouldn't this use the containing block chain, not
smcgruer
2017/04/26 14:37:07
No longer relevant; see new PS.
|
| + Parent()->EnclosingBoxModelObject()->IsInStickySubtree()); |
| } |
| } |