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

Unified Diff: gm/gradients_no_texture.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/gm.h ('k') | gm/imagefiltersbase.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/gradients_no_texture.cpp
diff --git a/gm/gradients_no_texture.cpp b/gm/gradients_no_texture.cpp
index e706ac634f597cbb13df2a55938b6651d27a81a1..d06ae5bdbf901ba63d144c04b83d49f5d94c0a3d 100644
--- a/gm/gradients_no_texture.cpp
+++ b/gm/gradients_no_texture.cpp
@@ -128,15 +128,15 @@ struct ColorPos {
ColorPos() : fColors(NULL), fPos(NULL), fCount(0) {}
~ColorPos() {
- SkDELETE_ARRAY(fColors);
- SkDELETE_ARRAY(fPos);
+ delete[] fColors;
+ delete[] fPos;
}
void construct(const SkColor colors[], const SkScalar pos[], int count) {
- fColors = SkNEW_ARRAY(SkColor, count);
+ fColors = new SkColor[count];
memcpy(fColors, colors, count * sizeof(SkColor));
if (pos) {
- fPos = SkNEW_ARRAY(SkScalar, count);
+ fPos = new SkScalar[count];
memcpy(fPos, pos, count * sizeof(SkScalar));
fPos[0] = 0;
fPos[count - 1] = 1;
@@ -248,5 +248,5 @@ private:
///////////////////////////////////////////////////////////////////////////////
-DEF_GM( return SkNEW(GradientsNoTextureGM));
-DEF_GM( return SkNEW(GradientsManyColorsGM));
+DEF_GM(return new GradientsNoTextureGM);
+DEF_GM(return new GradientsManyColorsGM);
« no previous file with comments | « gm/gm.h ('k') | gm/imagefiltersbase.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698