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

Unified Diff: third_party/WebKit/Source/platform/graphics/paint/PaintProperties.h

Issue 1390933003: Implement the framework for the paint property hierarchy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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/platform/graphics/paint/PaintProperties.h
diff --git a/third_party/WebKit/Source/platform/graphics/paint/PaintProperties.h b/third_party/WebKit/Source/platform/graphics/paint/PaintProperties.h
index 69a6651de7ed9dc39f562fcb2b79e711512dbbb6..cfd9780e84b1d3b70b3bef0dd82780b78bb6ddc4 100644
--- a/third_party/WebKit/Source/platform/graphics/paint/PaintProperties.h
+++ b/third_party/WebKit/Source/platform/graphics/paint/PaintProperties.h
@@ -5,21 +5,26 @@
#ifndef PaintProperties_h
#define PaintProperties_h
+#include "platform/graphics/paint/TransformPaintProperty.h"
+
#include <iosfwd>
namespace blink {
-// The set of paint properties applying to a |PaintChunk|.
-// In particular, this does not mean properties like background-color, but
-// rather the hierarchy of transforms, clips, effects, etc. that apply to a
-// contiguous chunk of drawings.
+// The set of paint properties applying to a |PaintChunk|. These properties are
+// not simple color changes but instead represent the hierachy of transforms,
+// clips, effects, etc, that apply to a contiguous chunk of display items.
+// A single DisplayItemClient can generate multiple properties of the same type
+// and this struct represents the total state of all properties for a given
+// |PaintChunk|.
struct PaintProperties {
- // TODO(jbroman): Add actual properties.
+ // TODO(pdr): Add clip, scroll, and effect properties.
+ RefPtr<TransformPaintProperty> transform;
};
-inline bool operator==(const PaintProperties&, const PaintProperties&)
+inline bool operator==(const PaintProperties& a, const PaintProperties& b)
{
- return true;
+ return a.transform.get() == b.transform.get();
}
inline bool operator!=(const PaintProperties& a, const PaintProperties& b)

Powered by Google App Engine
This is Rietveld 408576698