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

Unified Diff: gm/rects.cpp

Issue 232913003: Make sure SkDrawLooper objects can only be allocated on the heap. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 6 years, 8 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/megalooper.cpp ('k') | gm/shadows.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/rects.cpp
diff --git a/gm/rects.cpp b/gm/rects.cpp
index febf553aa159c187027b862daad3acdec9e66cf1..9600dd5ed5ad73a0e2a0a7193f1af7602f893b31 100644
--- a/gm/rects.cpp
+++ b/gm/rects.cpp
@@ -95,12 +95,12 @@ protected:
p.setColor(SK_ColorWHITE);
p.setAntiAlias(true);
SkBlurDrawLooper* shadowLooper =
- new SkBlurDrawLooper (SK_ColorWHITE,
- SkBlurMask::ConvertRadiusToSigma(SkIntToScalar(10)),
- SkIntToScalar(5), SkIntToScalar(10),
- SkBlurDrawLooper::kIgnoreTransform_BlurFlag |
- SkBlurDrawLooper::kOverrideColor_BlurFlag |
- SkBlurDrawLooper::kHighQuality_BlurFlag);
+ SkBlurDrawLooper::Create(SK_ColorWHITE,
+ SkBlurMask::ConvertRadiusToSigma(SkIntToScalar(10)),
+ SkIntToScalar(5), SkIntToScalar(10),
+ SkBlurDrawLooper::kIgnoreTransform_BlurFlag |
+ SkBlurDrawLooper::kOverrideColor_BlurFlag |
+ SkBlurDrawLooper::kHighQuality_BlurFlag);
SkAutoUnref aurL0(shadowLooper);
p.setLooper(shadowLooper);
fPaints.push_back(p);
« no previous file with comments | « gm/megalooper.cpp ('k') | gm/shadows.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698