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

Unified Diff: src/pipe/SkGPipeWrite.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/pipe/SkGPipeRead.cpp ('k') | src/ports/SkFontConfigInterface_direct.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pipe/SkGPipeWrite.cpp
diff --git a/src/pipe/SkGPipeWrite.cpp b/src/pipe/SkGPipeWrite.cpp
index aa04cb88f31ed07388fc2ddcbff7a1ab4dbf91bb..b74b36d0cc30c71c19084864f99b1c93aedd1323 100644
--- a/src/pipe/SkGPipeWrite.cpp
+++ b/src/pipe/SkGPipeWrite.cpp
@@ -437,15 +437,16 @@ int SkGPipeCanvas::flattenToIndex(SkFlattenable* obj, PaintFlats paintflat) {
#define FLATTENABLES_TO_KEEP 10
SkGPipeCanvas::SkGPipeCanvas(SkGPipeController* controller,
- SkWriter32* writer, uint32_t flags,
- uint32_t width, uint32_t height)
+ SkWriter32* writer,
+ uint32_t flags,
+ uint32_t width,
+ uint32_t height)
: SkCanvas(width, height)
- , fFactorySet(is_cross_process(flags) ? SkNEW(SkNamedFactorySet) : NULL)
+ , fFactorySet(is_cross_process(flags) ? new SkNamedFactorySet : NULL)
, fWriter(*writer)
, fFlags(flags)
, fFlattenableHeap(FLATTENABLES_TO_KEEP, fFactorySet, is_cross_process(flags))
- , fFlatDictionary(&fFlattenableHeap)
-{
+ , fFlatDictionary(&fFlattenableHeap) {
fController = controller;
fDone = false;
fBlockSize = 0; // need first block from controller
@@ -458,11 +459,10 @@ SkGPipeCanvas::SkGPipeCanvas(SkGPipeController* controller,
}
if (shouldFlattenBitmaps(flags)) {
- fBitmapShuttle.reset(SkNEW_ARGS(BitmapShuttle, (this)));
- fBitmapHeap = SkNEW_ARGS(SkBitmapHeap, (fBitmapShuttle.get(), BITMAPS_TO_KEEP));
+ fBitmapShuttle.reset(new BitmapShuttle(this));
+ fBitmapHeap = new SkBitmapHeap(fBitmapShuttle.get(), BITMAPS_TO_KEEP);
} else {
- fBitmapHeap = SkNEW_ARGS(SkBitmapHeap,
- (BITMAPS_TO_KEEP, controller->numberOfReaders()));
+ fBitmapHeap = new SkBitmapHeap(BITMAPS_TO_KEEP, controller->numberOfReaders());
if (this->needOpBytes(sizeof(void*))) {
this->writeOp(kShareBitmapHeap_DrawOp);
fWriter.writePtr(static_cast<void*>(fBitmapHeap));
@@ -470,7 +470,7 @@ SkGPipeCanvas::SkGPipeCanvas(SkGPipeController* controller,
}
fFlattenableHeap.setBitmapStorage(fBitmapHeap);
- fImageHeap = SkNEW(SkImageHeap);
+ fImageHeap = new SkImageHeap;
if (this->needOpBytes(sizeof(void*))) {
this->writeOp(kShareImageHeap_DrawOp);
fWriter.writePtr(static_cast<void*>(fImageHeap));
@@ -1399,7 +1399,7 @@ SkCanvas* SkGPipeWriter::startRecording(SkGPipeController* controller, uint32_t
uint32_t width, uint32_t height) {
if (NULL == fCanvas) {
fWriter.reset(NULL, 0);
- fCanvas = SkNEW_ARGS(SkGPipeCanvas, (controller, &fWriter, flags, width, height));
+ fCanvas = new SkGPipeCanvas(controller, &fWriter, flags, width, height);
}
controller->setCanvas(fCanvas);
return fCanvas;
« no previous file with comments | « src/pipe/SkGPipeRead.cpp ('k') | src/ports/SkFontConfigInterface_direct.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698