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

Unified Diff: src/doc/SkDocument_XPS.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/doc/SkDocument_PDF.cpp ('k') | src/effects/SkAlphaThresholdFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/doc/SkDocument_XPS.cpp
diff --git a/src/doc/SkDocument_XPS.cpp b/src/doc/SkDocument_XPS.cpp
index 884d9a5c4516807b4c5af746fc360ee1a8407ff4..943d0a882a377ec82a7c3a47b939eadbe60e19b6 100644
--- a/src/doc/SkDocument_XPS.cpp
+++ b/src/doc/SkDocument_XPS.cpp
@@ -33,7 +33,7 @@ protected:
const SkRect& trimBox) override {
fDevice.beginSheet(fUnitsPerMeter, fPixelsPerMeter,
SkSize::Make(width, height));
- fCanvas.reset(SkNEW_ARGS(SkCanvas, (&fDevice)));
+ fCanvas.reset(new SkCanvas(&fDevice));
fCanvas->clipRect(trimBox);
fCanvas->translate(trimBox.x(), trimBox.y());
return fCanvas.get();
@@ -63,17 +63,15 @@ private:
///////////////////////////////////////////////////////////////////////////////
SkDocument* SkDocument::CreateXPS(SkWStream* stream, SkScalar dpi) {
- return stream ? SkNEW_ARGS(SkDocument_XPS, (stream, NULL, dpi)) : NULL;
+ return stream ? new SkDocument_XPS(stream, NULL, dpi) : NULL;
}
-static void delete_wstream(SkWStream* stream, bool aborted) {
- SkDELETE(stream);
-}
+static void delete_wstream(SkWStream* stream, bool aborted) { delete stream; }
SkDocument* SkDocument::CreateXPS(const char path[], SkScalar dpi) {
- SkAutoTDelete<SkFILEWStream> stream(SkNEW_ARGS(SkFILEWStream, (path)));
+ SkAutoTDelete<SkFILEWStream> stream(new SkFILEWStream(path));
if (!stream->isValid()) {
return NULL;
}
- return SkNEW_ARGS(SkDocument_XPS, (stream.detach(), delete_wstream, dpi));
+ return new SkDocument_XPS(stream.detach(), delete_wstream, dpi);
}
« no previous file with comments | « src/doc/SkDocument_PDF.cpp ('k') | src/effects/SkAlphaThresholdFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698