aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrResourceCache.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gpu/GrResourceCache.h')
-rw-r--r--src/gpu/GrResourceCache.h14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/gpu/GrResourceCache.h b/src/gpu/GrResourceCache.h
index 162e1ef04a..5741e47dc9 100644
--- a/src/gpu/GrResourceCache.h
+++ b/src/gpu/GrResourceCache.h
@@ -264,12 +264,15 @@ public:
void makeNonExclusive(GrResourceEntry* entry);
/**
- * When done with an entry, call unlock(entry) on it, which returns it to
- * a purgable state.
+ * When done with an entry, call unlock(entry) on it, which returns it to
+ * a purgable state.
*/
void unlock(GrResourceEntry*);
- void removeAll();
+ /**
+ * Removes every resource in the cache that isn't locked.
+ */
+ void purgeAllUnlocked();
#if GR_DEBUG
void validate() const;
@@ -289,11 +292,12 @@ private:
GrTHashTable<GrResourceEntry, Key, 8> fCache;
// manage the dlink list
- SkTDLinkedList<GrResourceEntry> fList;
+ typedef SkTDLinkedList<GrResourceEntry> EntryList;
+ EntryList fList;
#if GR_DEBUG
// These objects cannot be returned by a search
- SkTDLinkedList<GrResourceEntry> fExclusiveList;
+ EntryList fExclusiveList;
#endif
// our budget, used in purgeAsNeeded()