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

Unified Diff: include/core/SkPixelRef.h

Issue 387313004: remove SK_SUPPORT_LEGACY_PIXELREF_UNFLATTENABLE code (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 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/SkMallocPixelRef.h ('k') | include/gpu/SkGrPixelRef.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkPixelRef.h
diff --git a/include/core/SkPixelRef.h b/include/core/SkPixelRef.h
index 263145ba3d90baefabd5552cefed18892fed1c02..80d138091615d3dba8c513be07b573862f99c25e 100644
--- a/include/core/SkPixelRef.h
+++ b/include/core/SkPixelRef.h
@@ -12,7 +12,6 @@
#include "SkDynamicAnnotations.h"
#include "SkRefCnt.h"
#include "SkString.h"
-#include "SkFlattenable.h"
#include "SkImageInfo.h"
#include "SkTDArray.h"
@@ -32,13 +31,6 @@
// #define SK_IGNORE_PIXELREF_SETPRELOCKED
#endif
-#ifdef SK_SUPPORT_LEGACY_PIXELREF_UNFLATTENABLE
- // we only support unflattening, not flattening
- #define SK_PIXELREF_BASECLASS SkFlattenable
-#else
- #define SK_PIXELREF_BASECLASS SkRefCnt
-#endif
-
class SkColorTable;
class SkData;
struct SkIRect;
@@ -54,7 +46,7 @@ class GrTexture;
This class can be shared/accessed between multiple threads.
*/
-class SK_API SkPixelRef : public SK_PIXELREF_BASECLASS {
+class SK_API SkPixelRef : public SkRefCnt {
public:
SK_DECLARE_INST_COUNT(SkPixelRef)
@@ -258,10 +250,6 @@ public:
virtual void globalUnref();
#endif
-#ifdef SK_SUPPORT_LEGACY_PIXELREF_UNFLATTENABLE
- SK_DEFINE_FLATTENABLE_TYPE(SkPixelRef)
-#endif
-
// Register a listener that may be called the next time our generation ID changes.
//
// We'll only call the listener if we're confident that we are the only SkPixelRef with this
@@ -372,11 +360,7 @@ private:
friend class SkBitmap; // only for cloneGenID
void cloneGenID(const SkPixelRef&);
-#ifdef SK_SUPPORT_LEGACY_PIXELREF_UNFLATTENABLE
- virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE { sk_throw(); }
-#endif
-
- typedef SK_PIXELREF_BASECLASS INHERITED;
+ typedef SkRefCnt INHERITED;
};
class SkPixelRefFactory : public SkRefCnt {
« no previous file with comments | « include/core/SkMallocPixelRef.h ('k') | include/gpu/SkGrPixelRef.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698