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

Unified Diff: include/core/SkImageInfo.h

Issue 2196743002: Add SkColorSpace::Equals() API (Closed) Base URL: https://skia.googlesource.com/skia.git@cscleanup
Patch Set: Fix logic Created 4 years, 5 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
« no previous file with comments | « include/core/SkColorSpace.h ('k') | src/codec/SkJpegCodec.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkImageInfo.h
diff --git a/include/core/SkImageInfo.h b/include/core/SkImageInfo.h
index f143503c6611a4650b0eb565e2d78dd9dcf4d733..cf50acacae4396332325dd759c2804509bf3eacf 100644
--- a/include/core/SkImageInfo.h
+++ b/include/core/SkImageInfo.h
@@ -289,12 +289,10 @@ public:
bool operator==(const SkImageInfo& other) const {
return fWidth == other.fWidth && fHeight == other.fHeight &&
fColorType == other.fColorType && fAlphaType == other.fAlphaType &&
- fColorSpace == other.fColorSpace;
+ SkColorSpace::Equals(fColorSpace.get(), other.fColorSpace.get());
}
bool operator!=(const SkImageInfo& other) const {
- return fWidth != other.fWidth || fHeight != other.fHeight ||
- fColorType != other.fColorType || fAlphaType != other.fAlphaType ||
- fColorSpace != other.fColorSpace;
+ return !(*this == other);
}
void unflatten(SkReadBuffer&);
« no previous file with comments | « include/core/SkColorSpace.h ('k') | src/codec/SkJpegCodec.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698