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

Unified Diff: include/gpu/GrGpuResource.h

Issue 1217573002: remove SkInstCnt (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: Created 5 years, 6 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/gpu/GrDrawContext.h ('k') | include/gpu/GrGpuResourceRef.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/gpu/GrGpuResource.h
diff --git a/include/gpu/GrGpuResource.h b/include/gpu/GrGpuResource.h
index 6f9855f17cf603d45d189f385e3284a266ec9953..d726115a7289127e1fd18dcee5810a984774fb8b 100644
--- a/include/gpu/GrGpuResource.h
+++ b/include/gpu/GrGpuResource.h
@@ -11,7 +11,6 @@
#include "GrResourceKey.h"
#include "GrTypesPriv.h"
#include "SkData.h"
-#include "SkInstCnt.h"
class GrContext;
class GrGpu;
@@ -46,8 +45,6 @@ class GrResourceCache;
*/
template <typename DERIVED> class GrIORef : public SkNoncopyable {
public:
- SK_DECLARE_INST_COUNT(GrIORef)
-
// Some of the signatures are written to mirror SkRefCnt so that GrGpuResource can work with
// templated helper classes (e.g. SkAutoTUnref). However, we have different categories of
// refs (e.g. pending reads). We also don't require thread safety as GrCacheable objects are
@@ -59,7 +56,7 @@ public:
void unref() const {
this->validate();
-
+
if (!(--fRefCnt)) {
if (!static_cast<const DERIVED*>(this)->notifyRefCountIsZero()) {
return;
@@ -141,7 +138,7 @@ private:
*/
class SK_API GrGpuResource : public GrIORef<GrGpuResource> {
public:
- SK_DECLARE_INST_COUNT(GrGpuResource)
+
enum LifeCycle {
/**
« no previous file with comments | « include/gpu/GrDrawContext.h ('k') | include/gpu/GrGpuResourceRef.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698