Index: include/effects/SkMagnifierImageFilter.h |
diff --git a/include/effects/SkMagnifierImageFilter.h b/include/effects/SkMagnifierImageFilter.h |
index bea03adab36a7594f3abebf71db0600eb8d929f2..739f1eec733167df3df5806de464918218c01a8f 100644 |
--- a/include/effects/SkMagnifierImageFilter.h |
+++ b/include/effects/SkMagnifierImageFilter.h |
@@ -14,13 +14,20 @@ |
class SK_API SkMagnifierImageFilter : public SkImageFilter { |
public: |
- static SkImageFilter* Create(const SkRect& src, SkScalar inset, SkImageFilter* input = NULL); |
+ static sk_sp<SkImageFilter> Make(const SkRect& src, SkScalar inset, sk_sp<SkImageFilter> input); |
SK_TO_STRING_OVERRIDE() |
SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkMagnifierImageFilter) |
+#ifdef SK_SUPPORT_LEGACY_IMAGEFILTER_PTR |
+ static SkImageFilter* Create(const SkRect& src, SkScalar inset, |
+ SkImageFilter* input = nullptr) { |
+ return Make(src, inset, sk_ref_sp<SkImageFilter>(input)).release(); |
+ } |
+#endif |
+ |
protected: |
- SkMagnifierImageFilter(const SkRect& srcRect, SkScalar inset, SkImageFilter* input); |
+ SkMagnifierImageFilter(const SkRect& srcRect, SkScalar inset, sk_sp<SkImageFilter> input); |
void flatten(SkWriteBuffer&) const override; |
bool onFilterImageDeprecated(Proxy*, const SkBitmap& src, const Context&, |