Index: cc/paint/paint_flags.h |
diff --git a/cc/paint/paint_flags.h b/cc/paint/paint_flags.h |
index b7e96c68e2ec48f4a5e9505a7c5ce3e3e1372aee..37b460d6bda362ebe2dcb7efa9ecac7133174319 100644 |
--- a/cc/paint/paint_flags.h |
+++ b/cc/paint/paint_flags.h |
@@ -7,7 +7,6 @@ |
#include "base/compiler_specific.h" |
#include "cc/paint/paint_export.h" |
-#include "cc/paint/paint_shader.h" |
#include "third_party/skia/include/core/SkCanvas.h" |
#include "third_party/skia/include/core/SkColorFilter.h" |
#include "third_party/skia/include/core/SkDrawLooper.h" |
@@ -19,6 +18,8 @@ |
namespace cc { |
+using PaintShader = SkShader; |
+ |
class CC_PAINT_EXPORT PaintFlags { |
public: |
enum Style { |
@@ -198,6 +199,14 @@ class CC_PAINT_EXPORT PaintFlags { |
return paint_.computeFastBounds(orig, storage); |
} |
+ bool operator==(const PaintFlags& flags) { return flags.paint_ == paint_; } |
+ bool operator!=(const PaintFlags& flags) { return flags.paint_ != paint_; } |
+ |
+ // Returns true if this just represents an opacity blend when |
+ // used as saveLayer flags. |
+ bool IsSimpleOpacity() const; |
+ bool SupportsFoldingAlpha() const; |
+ |
private: |
friend const SkPaint& ToSkPaint(const PaintFlags& flags); |
friend const SkPaint* ToSkPaint(const PaintFlags* flags); |