diff options
author | 2015-08-26 13:07:48 -0700 | |
---|---|---|
committer | 2015-08-26 13:07:49 -0700 | |
commit | 385fe4d4b62d7d1dd76116dd570df3290a2f487b (patch) | |
tree | 53d982ff238828331e86acd44071a44162a8688c /experimental | |
parent | 5015176adf046ef906a2313b6e6b64b72cc84898 (diff) |
Style Change: SkNEW->new; SkDELETE->delete
DOCS_PREVIEW= https://skia.org/?cl=1316123003
Review URL: https://codereview.chromium.org/1316123003
Diffstat (limited to 'experimental')
-rw-r--r-- | experimental/SimpleCocoaApp/SimpleApp.mm | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/experimental/SimpleCocoaApp/SimpleApp.mm b/experimental/SimpleCocoaApp/SimpleApp.mm index 7dac2a4fff..6f9958f7fc 100644 --- a/experimental/SimpleCocoaApp/SimpleApp.mm +++ b/experimental/SimpleCocoaApp/SimpleApp.mm @@ -1,3 +1,9 @@ +/* + * Copyright 2011 Google Inc. + * + * Use of this source code is governed by a BSD-style license that can be + * found in the LICENSE file. + */ #include "SkCanvas.h" #include "SkCGUtils.h" #include "SkGraphics.h" @@ -23,15 +29,14 @@ static SkPicture* LoadPicture(const char path[]) { SkBitmap bm; if (SkImageDecoder::DecodeFile(path, &bm)) { bm.setImmutable(); - pic = SkNEW(SkPicture); + pic = new SkPicture; SkCanvas* can = pic->beginRecording(bm.width(), bm.height()); can->drawBitmap(bm, 0, 0, NULL); pic->endRecording(); } else { SkFILEStream stream(path); if (stream.isValid()) { - pic = SkNEW_ARGS(SkPicture, - (&stream, NULL, &SkImageDecoder::DecodeStream)); + pic = new SkPicture(&stream, NULL, &SkImageDecoder::DecodeStream); } if (false) { // re-record @@ -247,7 +252,7 @@ void application_init() { canvas.divName(filename, false); SkPicture* pic = LoadPicture(path.c_str()); pic->draw(&canvas); - SkDELETE(pic); + delete pic; } SkDebugf("\n</div>\n\n"); @@ -261,7 +266,7 @@ void application_init() { canvas.divName(filename, true); SkPicture* pic = LoadPicture(path.c_str()); pic->draw(&canvas); - SkDELETE(pic); + delete pic; } SkDebugf("];\n\n"); |