Chromium Code Reviews| Index: src/core/SkScaledImageCache.h |
| diff --git a/src/core/SkScaledImageCache.h b/src/core/SkScaledImageCache.h |
| index fee69d2d58598eb8fee6a7562a45bd2940912e6f..a55c9384ce185fcb9e06aa6138c5a197590adb52 100644 |
| --- a/src/core/SkScaledImageCache.h |
| +++ b/src/core/SkScaledImageCache.h |
| @@ -31,6 +31,8 @@ public: |
| * instance of this cache. |
| */ |
| + static SkScaledImageCache* Instance(); |
|
scroggo
2013/10/31 21:53:06
I think typically our functions to get the global
hal.canary
2013/11/01 03:29:24
Done.
|
| + |
| static ID* FindAndLock(uint32_t pixelGenerationID, |
| int32_t width, |
| int32_t height, |
| @@ -59,7 +61,7 @@ public: |
| /////////////////////////////////////////////////////////////////////////// |
| - SkScaledImageCache(size_t byteLimit); |
| + SkScaledImageCache(size_t byteLimit, SkBaseMutex* mutex = NULL); |
| ~SkScaledImageCache(); |
| /** |
| @@ -114,8 +116,8 @@ public: |
| */ |
| void unlock(ID*); |
| - size_t getBytesUsed() const { return fBytesUsed; } |
| - size_t getByteLimit() const { return fByteLimit; } |
| + size_t getBytesUsed() const; |
| + size_t getByteLimit() const; |
| /** |
| * Set the maximum number of bytes available to this cache. If the current |
| @@ -127,6 +129,8 @@ public: |
| public: |
| struct Rec; |
| private: |
| + SkBaseMutex* fMutex; // can be NULL |
| + |
| Rec* fHead; |
| Rec* fTail; |