Index: src/image/SkDataPixelRef.cpp |
diff --git a/src/image/SkDataPixelRef.cpp b/src/image/SkDataPixelRef.cpp |
index 980b4f145176b4ed5977406ba4c3f5095c02815f..0524243366c16cdf079cd8434dcd10d31500fc54 100644 |
--- a/src/image/SkDataPixelRef.cpp |
+++ b/src/image/SkDataPixelRef.cpp |
@@ -29,11 +29,11 @@ void SkDataPixelRef::onUnlockPixels() { |
void SkDataPixelRef::flatten(SkFlattenableWriteBuffer& buffer) const { |
this->INHERITED::flatten(buffer); |
- buffer.writeFlattenable(fData); |
+ buffer.writeDataAsByteArray(fData); |
} |
SkDataPixelRef::SkDataPixelRef(SkFlattenableReadBuffer& buffer) |
: INHERITED(buffer, NULL) { |
- fData = (SkData*)buffer.readFlattenable(); |
+ fData = buffer.readByteArrayAsData(); |
this->setPreLocked(const_cast<void*>(fData->data()), NULL); |
} |