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

Unified Diff: gm/textbloblooper.cpp

Issue 1813123003: Reland of "switch patheffects over to sk_sp (patchset #5 id:80001 of https://codereview.chromium.or… (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: move flag into sktypes, so it is visible to both paint and other patheffect clients 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 | « gm/stroketext.cpp ('k') | gm/texteffects.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/textbloblooper.cpp
diff --git a/gm/textbloblooper.cpp b/gm/textbloblooper.cpp
index 8d462c9b0902658cd8d29dcd1bdf7824c615cc1f..d54490272c8e52b513bcaebab25df1f2942b75f6 100644
--- a/gm/textbloblooper.cpp
+++ b/gm/textbloblooper.cpp
@@ -66,18 +66,18 @@ static void mask_filter(SkPaint* paint) {
paint->setMaskFilter(mf)->unref();
}
-static SkPathEffect* make_tile_effect() {
+static sk_sp<SkPathEffect> make_tile_effect() {
SkMatrix m;
m.setScale(1.f, 1.f);
SkPath path;
path.addCircle(0, 0, SkIntToScalar(5));
- return SkPath2DPathEffect::Create(m, path);
+ return SkPath2DPathEffect::Make(m, path);
}
static void path_effect(SkPaint* paint) {
- paint->setPathEffect(make_tile_effect())->unref();
+ paint->setPathEffect(make_tile_effect());
}
static sk_sp<SkShader> make_shader(const SkRect& bounds) {
« no previous file with comments | « gm/stroketext.cpp ('k') | gm/texteffects.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698