Index: src/effects/SkXfermodeImageFilter.cpp |
diff --git a/src/effects/SkXfermodeImageFilter.cpp b/src/effects/SkXfermodeImageFilter.cpp |
index c876d5f6b3759b89505d114ec6fd292636b667d1..15ff92acf48f96d469de61a439519f92c4248e88 100644 |
--- a/src/effects/SkXfermodeImageFilter.cpp |
+++ b/src/effects/SkXfermodeImageFilter.cpp |
@@ -31,10 +31,18 @@ SkXfermodeImageFilter::~SkXfermodeImageFilter() { |
SkSafeUnref(fMode); |
} |
+#ifdef SK_SUPPORT_LEGACY_DEEPFLATTENING |
SkXfermodeImageFilter::SkXfermodeImageFilter(SkReadBuffer& buffer) |
: INHERITED(2, buffer) { |
fMode = buffer.readXfermode(); |
} |
+#endif |
+ |
+SkFlattenable* SkXfermodeImageFilter::CreateProc(SkReadBuffer& buffer) { |
+ SK_IMAGEFILTER_UNFLATTEN_COMMON(common, 2); |
+ SkAutoTUnref<SkXfermode> mode(buffer.readXfermode()); |
+ return Create(mode, common.getInput(0), common.getInput(1), &common.cropRect()); |
+} |
void SkXfermodeImageFilter::flatten(SkWriteBuffer& buffer) const { |
this->INHERITED::flatten(buffer); |