Index: src/effects/SkLerpXfermode.cpp |
diff --git a/src/effects/SkLerpXfermode.cpp b/src/effects/SkLerpXfermode.cpp |
index c8389fea799c7fe5181cb065410dd5785134fb39..0376a57b64f0a2921d707123a11af1883413ab00 100644 |
--- a/src/effects/SkLerpXfermode.cpp |
+++ b/src/effects/SkLerpXfermode.cpp |
@@ -23,16 +23,20 @@ SkXfermode* SkLerpXfermode::Create(SkScalar scale) { |
SkLerpXfermode::SkLerpXfermode(unsigned scale256) : fScale256(scale256) {} |
-SkLerpXfermode::SkLerpXfermode(SkReadBuffer& buffer) |
- : INHERITED(buffer) { |
+#ifdef SK_SUPPORT_LEGACY_DEEPFLATTENING |
+SkLerpXfermode::SkLerpXfermode(SkReadBuffer& buffer) : INHERITED(buffer) { |
fScale256 = buffer.readUInt(); |
} |
+#endif |
void SkLerpXfermode::flatten(SkWriteBuffer& buffer) const { |
- this->INHERITED::flatten(buffer); |
buffer.writeUInt(fScale256); |
} |
+SkFlattenable* SkLerpXfermode::CreateProc(SkReadBuffer& buffer) { |
+ return SkNEW_ARGS(SkLerpXfermode, (buffer.readUInt())); |
+} |
+ |
void SkLerpXfermode::xfer32(SkPMColor dst[], const SkPMColor src[], int count, |
const SkAlpha aa[]) const { |
const int scale = fScale256; |