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

Unified Diff: third_party/WebKit/Source/core/paint/PaintLayer.h

Issue 1397583002: Implement the framework for a paint property hierarchy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Job insecurity: better tests, better comments, better names. Created 5 years, 2 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/paint/PaintLayer.h
diff --git a/third_party/WebKit/Source/core/paint/PaintLayer.h b/third_party/WebKit/Source/core/paint/PaintLayer.h
index 2f61c2e2a2da838ab959c646a21c8d7f44d5ecc0..a9a836003993c002b98c7d9162807a9ebcfb787f 100644
--- a/third_party/WebKit/Source/core/paint/PaintLayer.h
+++ b/third_party/WebKit/Source/core/paint/PaintLayer.h
@@ -66,6 +66,7 @@ class FilterOperations;
class HitTestRequest;
class HitTestResult;
class HitTestingTransformState;
+class ObjectPaintProperties;
class PaintLayerCompositor;
class CompositedLayerMapping;
class ComputedStyle;
@@ -568,6 +569,12 @@ public:
// For subsequence display items.
DisplayItemClient displayItemClient() const { return toDisplayItemClient(this); }
+ // Paint properties encode the hierarchical transform, clip, scroll, and
+ // effect information used for painting. Properties should only be changed
+ // during UpdatePaintProperties, and should only be used during Paint.
+ ObjectPaintProperties& mutablePaintProperties();
+ const ObjectPaintProperties* paintProperties() const;
+
private:
// Bounding box in the coordinates of this layer.
LayoutRect logicalBoundingBox() const;
@@ -752,6 +759,11 @@ private:
OwnPtr<PaintLayerStackingNode> m_stackingNode;
OwnPtr<PaintLayerReflectionInfo> m_reflectionInfo;
+ // Lazily-allocated paint properties for m_layoutObject, stored here to
+ // reduce memory usage as PaintLayers are created for all paint property
+ // layout objects.
+ OwnPtr<ObjectPaintProperties> m_paintProperties;
+
LayoutSize m_subpixelAccumulation; // The accumulated subpixel offset of a composited layer's composited bounds compared to absolute coordinates.
IntSize m_previousScrollOffsetAccumulationForPainting;
« no previous file with comments | « third_party/WebKit/Source/core/paint/ObjectPaintProperties.h ('k') | third_party/WebKit/Source/core/paint/PaintLayer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698