| Index: include/core/SkTDArray.h
|
| diff --git a/include/core/SkTDArray.h b/include/core/SkTDArray.h
|
| index 14447217e93416626d06d820d0b2b0d58d441987..67254ccc9a88fa93fe6489ea82bccb6efe8959e6 100644
|
| --- a/include/core/SkTDArray.h
|
| +++ b/include/core/SkTDArray.h
|
| @@ -101,6 +101,13 @@ public:
|
| int count() const { return fCount; }
|
|
|
| /**
|
| + * Return the total number of elements allocated.
|
| + * reserved() - count() gives you the number of elements you can add
|
| + * without causing an allocation.
|
| + */
|
| + int reserved() const { return fReserve; }
|
| +
|
| + /**
|
| * return the number of bytes in the array: count * sizeof(T)
|
| */
|
| size_t bytes() const { return fCount * sizeof(T); }
|
|
|