Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(131)

Unified Diff: src/core/SkMatrixImageFilter.cpp

Issue 1855733002: change flattenable factory to return sk_sp (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/core/SkLocalMatrixShader.cpp ('k') | src/core/SkModeColorFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkMatrixImageFilter.cpp
diff --git a/src/core/SkMatrixImageFilter.cpp b/src/core/SkMatrixImageFilter.cpp
index d66772c2447072d88f1ebee201da336f78e5e118..70bc81af434bdaeda0d1971194745745bb12ce93 100644
--- a/src/core/SkMatrixImageFilter.cpp
+++ b/src/core/SkMatrixImageFilter.cpp
@@ -28,12 +28,12 @@ SkMatrixImageFilter* SkMatrixImageFilter::Create(const SkMatrix& transform,
return new SkMatrixImageFilter(transform, filterQuality, input);
}
-SkFlattenable* SkMatrixImageFilter::CreateProc(SkReadBuffer& buffer) {
+sk_sp<SkFlattenable> SkMatrixImageFilter::CreateProc(SkReadBuffer& buffer) {
SK_IMAGEFILTER_UNFLATTEN_COMMON(common, 1);
SkMatrix matrix;
buffer.readMatrix(&matrix);
SkFilterQuality quality = static_cast<SkFilterQuality>(buffer.readInt());
- return Create(matrix, quality, common.getInput(0).get());
+ return sk_sp<SkImageFilter>(Create(matrix, quality, common.getInput(0).get()));
}
void SkMatrixImageFilter::flatten(SkWriteBuffer& buffer) const {
« no previous file with comments | « src/core/SkLocalMatrixShader.cpp ('k') | src/core/SkModeColorFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698