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

Unified Diff: cc/layers/layer_sticky_position_constraint.h

Issue 2733633002: Handle nested position:sticky elements correctly (compositor) (Closed)
Patch Set: Fix unittest Created 3 years, 9 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: cc/layers/layer_sticky_position_constraint.h
diff --git a/cc/layers/layer_sticky_position_constraint.h b/cc/layers/layer_sticky_position_constraint.h
index 3f43bc7751ab614b2c12b25c18d73a71cd308012..55e832ae6182c9cc94e4b520122aebc8531d5d05 100644
--- a/cc/layers/layer_sticky_position_constraint.h
+++ b/cc/layers/layer_sticky_position_constraint.h
@@ -11,6 +11,8 @@
namespace cc {
+class Layer;
+
struct CC_EXPORT LayerStickyPositionConstraint {
LayerStickyPositionConstraint();
LayerStickyPositionConstraint(const LayerStickyPositionConstraint& other);
@@ -44,6 +46,14 @@ struct CC_EXPORT LayerStickyPositionConstraint {
// block boundary.
gfx::Rect scroll_container_relative_containing_block_rect;
+ Layer* nearest_layer_shifting_sticky_box;
+ Layer* nearest_layer_shifting_containing_block;
+
+ gfx::Vector2dF total_sticky_box_sticky_offset;
+ gfx::Vector2dF total_containing_block_sticky_offset;
+
+ gfx::Vector2dF local_sticky_offset;
+
bool operator==(const LayerStickyPositionConstraint&) const;
bool operator!=(const LayerStickyPositionConstraint&) const;
};

Powered by Google App Engine
This is Rietveld 408576698