| Index: src/core/SkDiscardableMemory.h
|
| diff --git a/src/core/SkDiscardableMemory.h b/src/core/SkDiscardableMemory.h
|
| index e1634eef4f4013a5945f4cb64f67b09c17d16271..7f401ed1e86d59da18bcc0d1f50a9e6ae183cc24 100644
|
| --- a/src/core/SkDiscardableMemory.h
|
| +++ b/src/core/SkDiscardableMemory.h
|
| @@ -9,6 +9,7 @@
|
| #define SkDiscardableMemory_DEFINED
|
|
|
| #include "SkTypes.h"
|
| +#include "SkRefCnt.h"
|
|
|
| /**
|
| * Interface for discardable memory. Implementation is provided by the
|
| @@ -23,6 +24,16 @@ public:
|
| */
|
| static SkDiscardableMemory* Create(size_t bytes);
|
|
|
| + /**
|
| + * Factory class that creates, initializes and locks an SkDiscardableMemory
|
| + * object. If either of these steps fails, a NULL pointer will be returned.
|
| + */
|
| + class Factory : public SkRefCnt {
|
| + public:
|
| + virtual SkDiscardableMemory* create(size_t bytes) = 0;
|
| + virtual ~Factory() { }
|
| + };
|
| +
|
| /** Must not be called while locked.
|
| */
|
| virtual ~SkDiscardableMemory() {}
|
|
|