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

Unified Diff: gm/multipicturedraw.cpp

Issue 1316123003: Style Change: SkNEW->new; SkDELETE->delete (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-26 (Wednesday) 15:59:00 EDT Created 5 years, 4 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/modecolorfilters.cpp ('k') | gm/patch.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/multipicturedraw.cpp
diff --git a/gm/multipicturedraw.cpp b/gm/multipicturedraw.cpp
index 21c9d187b38905c306a8879dd948ae853c84abaa..3a0b0fa7d9e02578280d1c11b6775fbba85188a7 100644
--- a/gm/multipicturedraw.cpp
+++ b/gm/multipicturedraw.cpp
@@ -258,7 +258,10 @@ static SkSurface* create_compat_surface(SkCanvas* canvas, int width, int height)
class ComposeStep {
public:
ComposeStep() : fSurf(NULL), fX(0.0f), fY(0.0f), fPaint(NULL) { }
- ~ComposeStep() { SkSafeUnref(fSurf); SkDELETE(fPaint); }
+ ~ComposeStep() {
+ SkSafeUnref(fSurf);
+ delete fPaint;
+ }
SkSurface* fSurf;
SkScalar fX;
@@ -415,7 +418,7 @@ static void tiled(SkCanvas* finalCanvas, SkMultiPictureDraw* mpd,
step.fX = SkIntToScalar(x*kTileWidth);
step.fY = SkIntToScalar(y*kTileHeight);
- step.fPaint = SkNEW(SkPaint);
+ step.fPaint = new SkPaint;
step.fPaint->setColorFilter(
SkColorFilter::CreateModeFilter(colors[x][y], SkXfermode::kModulate_Mode))->unref();
@@ -540,33 +543,33 @@ namespace skiagm {
typedef GM INHERITED;
};
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kNoClipSingle_Content,
- MultiPictureDraw::kSimple_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kRectClipMulti_Content,
- MultiPictureDraw::kSimple_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kRRectClipMulti_Content,
- MultiPictureDraw::kSimple_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kPathClipMulti_Content,
- MultiPictureDraw::kSimple_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kInvPathClipMulti_Content,
- MultiPictureDraw::kSimple_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kSierpinski_Content,
- MultiPictureDraw::kSimple_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kBigLayer_Content,
- MultiPictureDraw::kSimple_Layout));)
-
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kNoClipSingle_Content,
- MultiPictureDraw::kTiled_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kRectClipMulti_Content,
- MultiPictureDraw::kTiled_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kRRectClipMulti_Content,
- MultiPictureDraw::kTiled_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kPathClipMulti_Content,
- MultiPictureDraw::kTiled_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kInvPathClipMulti_Content,
- MultiPictureDraw::kTiled_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kSierpinski_Content,
- MultiPictureDraw::kTiled_Layout));)
- DEF_GM(return SkNEW_ARGS(MultiPictureDraw, (MultiPictureDraw::kBigLayer_Content,
- MultiPictureDraw::kTiled_Layout));)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kNoClipSingle_Content,
+ MultiPictureDraw::kSimple_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kRectClipMulti_Content,
+ MultiPictureDraw::kSimple_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kRRectClipMulti_Content,
+ MultiPictureDraw::kSimple_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kPathClipMulti_Content,
+ MultiPictureDraw::kSimple_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kInvPathClipMulti_Content,
+ MultiPictureDraw::kSimple_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kSierpinski_Content,
+ MultiPictureDraw::kSimple_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kBigLayer_Content,
+ MultiPictureDraw::kSimple_Layout);)
+
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kNoClipSingle_Content,
+ MultiPictureDraw::kTiled_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kRectClipMulti_Content,
+ MultiPictureDraw::kTiled_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kRRectClipMulti_Content,
+ MultiPictureDraw::kTiled_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kPathClipMulti_Content,
+ MultiPictureDraw::kTiled_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kInvPathClipMulti_Content,
+ MultiPictureDraw::kTiled_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kSierpinski_Content,
+ MultiPictureDraw::kTiled_Layout);)
+ DEF_GM(return new MultiPictureDraw(MultiPictureDraw::kBigLayer_Content,
+ MultiPictureDraw::kTiled_Layout);)
}
« no previous file with comments | « gm/modecolorfilters.cpp ('k') | gm/patch.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698