| scroggo | b7e9aee | 2011-03-15 15:15:15 +0000 | [diff] [blame^] | 1 | #include "SkCanvas.h" |
| 2 | #include "SkColor.h" | ||||
| 3 | #include "SampleCode.h" | ||||
| 4 | #include "SkView.h" | ||||
| 5 | |||||
| 6 | class DrawBlue : public SkView { | ||||
| 7 | |||||
| 8 | public: | ||||
| 9 | DrawBlue() {} | ||||
| 10 | protected: | ||||
| 11 | virtual void onDraw(SkCanvas* canvas) { | ||||
| 12 | canvas->drawColor(SK_ColorBLUE); | ||||
| 13 | } | ||||
| 14 | }; | ||||
| 15 | |||||
| 16 | static SkView* MyFactory() { return new DrawBlue; } | ||||
| 17 | static SkViewRegister reg(MyFactory); | ||||