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

Unified Diff: src/core/SkLocalMatrixShader.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/SkLocalMatrixImageFilter.cpp ('k') | src/core/SkMatrixImageFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkLocalMatrixShader.cpp
diff --git a/src/core/SkLocalMatrixShader.cpp b/src/core/SkLocalMatrixShader.cpp
index ddd6114ca870c95c6e9095bf5428c314c6d38134..ea4db5352c3f7708baef81d5a767e8c0ca126232 100644
--- a/src/core/SkLocalMatrixShader.cpp
+++ b/src/core/SkLocalMatrixShader.cpp
@@ -7,14 +7,14 @@
#include "SkLocalMatrixShader.h"
-SkFlattenable* SkLocalMatrixShader::CreateProc(SkReadBuffer& buffer) {
+sk_sp<SkFlattenable> SkLocalMatrixShader::CreateProc(SkReadBuffer& buffer) {
SkMatrix lm;
buffer.readMatrix(&lm);
auto baseShader(buffer.readShader());
if (!baseShader) {
return nullptr;
}
- return baseShader->makeWithLocalMatrix(lm).release();
+ return baseShader->makeWithLocalMatrix(lm);
}
void SkLocalMatrixShader::flatten(SkWriteBuffer& buffer) const {
« no previous file with comments | « src/core/SkLocalMatrixImageFilter.cpp ('k') | src/core/SkMatrixImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698