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

Side by Side Diff: samplecode/SampleApp.h

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/SampleAnimator.cpp ('k') | samplecode/SampleApp.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 * Copyright 2011 Skia 2 * Copyright 2011 Skia
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SampleApp_DEFINED 8 #ifndef SampleApp_DEFINED
9 #define SampleApp_DEFINED 9 #define SampleApp_DEFINED
10 10
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 // called after drawing, should get the results onto the 80 // called after drawing, should get the results onto the
81 // screen. 81 // screen.
82 virtual void publishCanvas(DeviceType dType, 82 virtual void publishCanvas(DeviceType dType,
83 SkCanvas* canvas, 83 SkCanvas* canvas,
84 SampleWindow* win) = 0; 84 SampleWindow* win) = 0;
85 85
86 // called when window changes size, guaranteed to be called 86 // called when window changes size, guaranteed to be called
87 // at least once before first draw (after init) 87 // at least once before first draw (after init)
88 virtual void windowSizeChanged(SampleWindow* win) = 0; 88 virtual void windowSizeChanged(SampleWindow* win) = 0;
89 89
90 // return the GrContext backing gpu devices (NULL if not built with GPU support) 90 // return the GrContext backing gpu devices (nullptr if not built with G PU support)
91 virtual GrContext* getGrContext() = 0; 91 virtual GrContext* getGrContext() = 0;
92 92
93 // return the GrRenderTarget backing gpu devices (NULL if not built with GPU support) 93 // return the GrRenderTarget backing gpu devices (nullptr if not built w ith GPU support)
94 virtual GrRenderTarget* getGrRenderTarget() = 0; 94 virtual GrRenderTarget* getGrRenderTarget() = 0;
95 private: 95 private:
96 typedef SkRefCnt INHERITED; 96 typedef SkRefCnt INHERITED;
97 }; 97 };
98 98
99 SampleWindow(void* hwnd, int argc, char** argv, DeviceManager*); 99 SampleWindow(void* hwnd, int argc, char** argv, DeviceManager*);
100 virtual ~SampleWindow(); 100 virtual ~SampleWindow();
101 101
102 SkSurface* createSurface() override { 102 SkSurface* createSurface() override {
103 SkSurface* surface = NULL; 103 SkSurface* surface = nullptr;
104 if (fDevManager) { 104 if (fDevManager) {
105 surface = fDevManager->createSurface(fDeviceType, this); 105 surface = fDevManager->createSurface(fDeviceType, this);
106 } 106 }
107 if (NULL == surface) { 107 if (nullptr == surface) {
108 surface = this->INHERITED::createSurface(); 108 surface = this->INHERITED::createSurface();
109 } 109 }
110 return surface; 110 return surface;
111 } 111 }
112 112
113 void draw(SkCanvas*) override; 113 void draw(SkCanvas*) override;
114 114
115 void setDeviceType(DeviceType type); 115 void setDeviceType(DeviceType type);
116 void toggleRendering(); 116 void toggleRendering();
117 void toggleSlideshow(); 117 void toggleSlideshow();
(...skipping 111 matching lines...) Expand 10 before | Expand all | Expand 10 after
229 void postAnimatingEvent(); 229 void postAnimatingEvent();
230 int findByTitle(const char*); 230 int findByTitle(const char*);
231 void listTitles(); 231 void listTitles();
232 SkSize tileSize() const; 232 SkSize tileSize() const;
233 bool sendAnimatePulse(); 233 bool sendAnimatePulse();
234 234
235 typedef SkOSWindow INHERITED; 235 typedef SkOSWindow INHERITED;
236 }; 236 };
237 237
238 #endif 238 #endif
OLDNEW
« no previous file with comments | « samplecode/SampleAnimator.cpp ('k') | samplecode/SampleApp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698