| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 Google Inc. |
| 3 * | 3 * |
| 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 */ | 8 */ |
| 9 | 9 |
| 10 #ifndef SkExample_DEFINED | 10 #ifndef SkExample_DEFINED |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 45 }; | 45 }; |
| 46 SkExampleWindow(void* hwnd); | 46 SkExampleWindow(void* hwnd); |
| 47 | 47 |
| 48 // Changes the device type of the object. | 48 // Changes the device type of the object. |
| 49 bool setupBackend(DeviceType type); | 49 bool setupBackend(DeviceType type); |
| 50 void tearDownBackend(); | 50 void tearDownBackend(); |
| 51 | 51 |
| 52 DeviceType getDeviceType() const { return fType; } | 52 DeviceType getDeviceType() const { return fType; } |
| 53 | 53 |
| 54 protected: | 54 protected: |
| 55 virtual void draw(SkCanvas* canvas) SK_OVERRIDE; | 55 void draw(SkCanvas* canvas) SK_OVERRIDE; |
| 56 | 56 |
| 57 virtual void onSizeChange() SK_OVERRIDE; | 57 void onSizeChange() SK_OVERRIDE; |
| 58 | 58 |
| 59 #ifdef SK_BUILD_FOR_WIN | 59 #ifdef SK_BUILD_FOR_WIN |
| 60 virtual void onHandleInval(const SkIRect&) SK_OVERRIDE; | 60 void onHandleInval(const SkIRect&) SK_OVERRIDE; |
| 61 #endif | 61 #endif |
| 62 | 62 |
| 63 SkCanvas* createCanvas() SK_OVERRIDE; | 63 SkCanvas* createCanvas() SK_OVERRIDE; |
| 64 | 64 |
| 65 private: | 65 private: |
| 66 bool findNextMatch(); // Set example to the first one that matches FLAGS_ma
tch. | 66 bool findNextMatch(); // Set example to the first one that matches FLAGS_ma
tch. |
| 67 void setupRenderTarget(); | 67 void setupRenderTarget(); |
| 68 bool onHandleChar(SkUnichar unichar) SK_OVERRIDE; | 68 bool onHandleChar(SkUnichar unichar) SK_OVERRIDE; |
| 69 | 69 |
| 70 DeviceType fType; | 70 DeviceType fType; |
| 71 | 71 |
| 72 SkExample* fCurrExample; | 72 SkExample* fCurrExample; |
| 73 const SkExample::Registry* fRegistry; | 73 const SkExample::Registry* fRegistry; |
| 74 GrContext* fContext; | 74 GrContext* fContext; |
| 75 GrRenderTarget* fRenderTarget; | 75 GrRenderTarget* fRenderTarget; |
| 76 AttachmentInfo fAttachmentInfo; | 76 AttachmentInfo fAttachmentInfo; |
| 77 const GrGLInterface* fInterface; | 77 const GrGLInterface* fInterface; |
| 78 | 78 |
| 79 typedef SkOSWindow INHERITED; | 79 typedef SkOSWindow INHERITED; |
| 80 }; | 80 }; |
| 81 | 81 |
| 82 #endif | 82 #endif |
| OLD | NEW |