diff options
author | John Reck <jreck@google.com> | 2014-11-06 19:22:28 +0000 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2014-11-06 19:22:28 +0000 |
commit | be70c7713df98d81e9e43af9e76e0e6d018a4339 (patch) | |
tree | f61d49c0e935ff423d90392ba24d2adfca00a275 /libs/hwui/ResourceCache.h | |
parent | 843133cd835b2923453bba95599aefa48fe8cb20 (diff) | |
parent | 327cb3184d5f5d9f22db9ab18a07bb71081bb446 (diff) | |
download | frameworks_base-be70c7713df98d81e9e43af9e76e0e6d018a4339.zip frameworks_base-be70c7713df98d81e9e43af9e76e0e6d018a4339.tar.gz frameworks_base-be70c7713df98d81e9e43af9e76e0e6d018a4339.tar.bz2 |
am 327cb318: Merge "Yank ResourceCache out of Caches" into lmp-mr1-dev automerge: 9c13b8c
* commit '327cb3184d5f5d9f22db9ab18a07bb71081bb446':
Yank ResourceCache out of Caches
Diffstat (limited to 'libs/hwui/ResourceCache.h')
-rw-r--r-- | libs/hwui/ResourceCache.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/libs/hwui/ResourceCache.h b/libs/hwui/ResourceCache.h index 8539d12..a922d53 100644 --- a/libs/hwui/ResourceCache.h +++ b/libs/hwui/ResourceCache.h @@ -22,6 +22,7 @@ #include <SkBitmap.h> #include <utils/KeyedVector.h> +#include <utils/Singleton.h> #include <androidfw/ResourceTypes.h> @@ -53,11 +54,14 @@ public: ResourceType resourceType; }; -class ANDROID_API ResourceCache { -public: +class ANDROID_API ResourceCache: public Singleton<ResourceCache> { ResourceCache(); ~ResourceCache(); + friend class Singleton<ResourceCache>; + +public: + /** * When using these two methods, make sure to only invoke the *Locked() * variants of increment/decrementRefcount(), recyle() and destructor() |