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

Unified Diff: src/c/sk_paint.cpp

Issue 1829303002: move setshader to sk_sp (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: addressing comments from #8 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/animator/SkDrawPaint.cpp ('k') | src/core/SkBlitter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/c/sk_paint.cpp
diff --git a/src/c/sk_paint.cpp b/src/c/sk_paint.cpp
index dd0733f02ed200707cd72fa0b32f64fe07e0beb6..b48e28fb6dcbddae6eb5f09b7db41aa94ec3d54d 100644
--- a/src/c/sk_paint.cpp
+++ b/src/c/sk_paint.cpp
@@ -6,6 +6,7 @@
*/
#include "SkPaint.h"
+#include "SkShader.h"
#include "sk_paint.h"
#include "sk_types_priv.h"
@@ -63,7 +64,7 @@ void sk_paint_set_color(sk_paint_t* cpaint, sk_color_t c) {
}
void sk_paint_set_shader(sk_paint_t* cpaint, sk_shader_t* cshader) {
- AsPaint(cpaint)->setShader(AsShader(cshader));
+ AsPaint(cpaint)->setShader(sk_ref_sp(AsShader(cshader)));
}
void sk_paint_set_maskfilter(sk_paint_t* cpaint, sk_maskfilter_t* cfilter) {
« no previous file with comments | « src/animator/SkDrawPaint.cpp ('k') | src/core/SkBlitter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698