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

Side by Side Diff: samplecode/SampleRepeatTile.cpp

Issue 1316233002: Style Change: NULL->nullptr (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 2015-08-27 (Thursday) 10:25:06 EDT Created 5 years, 3 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 unified diff | Download patch
« no previous file with comments | « samplecode/SampleRegion.cpp ('k') | samplecode/SampleShaderText.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 #include "SampleCode.h" 8 #include "SampleCode.h"
9 #include "SkView.h" 9 #include "SkView.h"
10 #include "SkCanvas.h" 10 #include "SkCanvas.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
60 void onDrawContent(SkCanvas* canvas) override { 60 void onDrawContent(SkCanvas* canvas) override {
61 SkPaint paint; 61 SkPaint paint;
62 make_paint(&paint, SkShader::kRepeat_TileMode); 62 make_paint(&paint, SkShader::kRepeat_TileMode);
63 63
64 // canvas->scale(SK_Scalar1*2, SK_Scalar1); 64 // canvas->scale(SK_Scalar1*2, SK_Scalar1);
65 canvas->translate(SkIntToScalar(100), SkIntToScalar(100)); 65 canvas->translate(SkIntToScalar(100), SkIntToScalar(100));
66 canvas->drawPaint(paint); 66 canvas->drawPaint(paint);
67 } 67 }
68 68
69 SkView::Click* onFindClickHandler(SkScalar x, SkScalar y, unsigned modi) ove rride { 69 SkView::Click* onFindClickHandler(SkScalar x, SkScalar y, unsigned modi) ove rride {
70 this->inval(NULL); 70 this->inval(nullptr);
71 71
72 return this->INHERITED::onFindClickHandler(x, y, modi); 72 return this->INHERITED::onFindClickHandler(x, y, modi);
73 } 73 }
74 74
75 bool onClick(Click* click) override { 75 bool onClick(Click* click) override {
76 return this->INHERITED::onClick(click); 76 return this->INHERITED::onClick(click);
77 } 77 }
78 78
79 virtual bool handleKey(SkKey) { 79 virtual bool handleKey(SkKey) {
80 this->inval(NULL); 80 this->inval(nullptr);
81 return true; 81 return true;
82 } 82 }
83 83
84 private: 84 private:
85 typedef SampleView INHERITED; 85 typedef SampleView INHERITED;
86 }; 86 };
87 87
88 ////////////////////////////////////////////////////////////////////////////// 88 //////////////////////////////////////////////////////////////////////////////
89 89
90 static SkView* MyFactory() { return new RepeatTileView; } 90 static SkView* MyFactory() { return new RepeatTileView; }
91 static SkViewRegister reg(MyFactory); 91 static SkViewRegister reg(MyFactory);
OLDNEW
« no previous file with comments | « samplecode/SampleRegion.cpp ('k') | samplecode/SampleShaderText.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698