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

Unified Diff: src/core/SkPictureShader.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 | « src/core/SkPictureRecorder.cpp ('k') | src/core/SkPixelRef.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkPictureShader.cpp
diff --git a/src/core/SkPictureShader.cpp b/src/core/SkPictureShader.cpp
index b84333939ed9aa34d3ef0d4f38031df99fcfea18..569ef3d822f96d05f6b6f2d8e8b648b6335b4271 100644
--- a/src/core/SkPictureShader.cpp
+++ b/src/core/SkPictureShader.cpp
@@ -124,7 +124,7 @@ SkShader* SkPictureShader::Create(const SkPicture* picture, TileMode tmx, TileMo
if (!picture || picture->cullRect().isEmpty() || (tile && tile->isEmpty())) {
return SkShader::CreateEmptyShader();
}
- return SkNEW_ARGS(SkPictureShader, (picture, tmx, tmy, localMatrix, tile));
+ return new SkPictureShader(picture, tmx, tmy, localMatrix, tile);
}
SkFlattenable* SkPictureShader::CreateProc(SkReadBuffer& buffer) {
@@ -250,7 +250,7 @@ SkShader* SkPictureShader::refBitmapShader(const SkMatrix& matrix, const SkMatri
shaderMatrix.preScale(1 / tileScale.width(), 1 / tileScale.height());
tileShader.reset(CreateBitmapShader(bm, fTmx, fTmy, &shaderMatrix));
- SkResourceCache::Add(SkNEW_ARGS(BitmapShaderRec, (key, tileShader.get(), bm.getSize())));
+ SkResourceCache::Add(new BitmapShaderRec(key, tileShader.get(), bm.getSize()));
}
return tileShader.detach();
@@ -272,8 +272,7 @@ SkShader::Context* SkPictureShader::onCreateContext(const ContextRec& rec, void*
SkShader::Context* SkPictureShader::PictureShaderContext::Create(void* storage,
const SkPictureShader& shader, const ContextRec& rec, SkShader* bitmapShader) {
- PictureShaderContext* ctx = SkNEW_PLACEMENT_ARGS(storage, PictureShaderContext,
- (shader, rec, bitmapShader));
+ PictureShaderContext* ctx = new (storage) PictureShaderContext(shader, rec, bitmapShader);
if (NULL == ctx->fBitmapShaderContext) {
ctx->~PictureShaderContext();
ctx = NULL;
« no previous file with comments | « src/core/SkPictureRecorder.cpp ('k') | src/core/SkPixelRef.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698