Index: src/image/SkDataPixelRef.cpp |
diff --git a/src/image/SkDataPixelRef.cpp b/src/image/SkDataPixelRef.cpp |
index 0524243366c16cdf079cd8434dcd10d31500fc54..b526e3650156514bcc3c4e053f8a7c552c3fe07d 100644 |
--- a/src/image/SkDataPixelRef.cpp |
+++ b/src/image/SkDataPixelRef.cpp |
@@ -27,6 +27,10 @@ void SkDataPixelRef::onUnlockPixels() { |
// nothing to do |
} |
+size_t SkDataPixelRef::getSize() const { |
+ return fData ? fData->size() : 0; |
+} |
+ |
void SkDataPixelRef::flatten(SkFlattenableWriteBuffer& buffer) const { |
this->INHERITED::flatten(buffer); |
buffer.writeDataAsByteArray(fData); |