| OLD | NEW |
| 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 699 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 710 return true; | 710 return true; |
| 711 } | 711 } |
| 712 return this->INHERITED::onQuery(evt); | 712 return this->INHERITED::onQuery(evt); |
| 713 } | 713 } |
| 714 | 714 |
| 715 virtual void onDrawContent(SkCanvas* canvas) { | 715 virtual void onDrawContent(SkCanvas* canvas) { |
| 716 this->init(); | 716 this->init(); |
| 717 gProc[fIndex](canvas); | 717 gProc[fIndex](canvas); |
| 718 } | 718 } |
| 719 | 719 |
| 720 virtual SkView::Click* onFindClickHandler(SkScalar x, SkScalar y) { | 720 virtual SkView::Click* onFindClickHandler(SkScalar x, SkScalar y, unsigned)
SK_OVERRIDE { |
| 721 this->init(); | 721 this->init(); |
| 722 fIndex = (fIndex + 1) % SK_ARRAY_COUNT(gProc); | 722 fIndex = (fIndex + 1) % SK_ARRAY_COUNT(gProc); |
| 723 this->inval(NULL); | 723 this->inval(NULL); |
| 724 return NULL; | 724 return NULL; |
| 725 } | 725 } |
| 726 | 726 |
| 727 private: | 727 private: |
| 728 typedef SampleView INHERITED; | 728 typedef SampleView INHERITED; |
| 729 }; | 729 }; |
| 730 | 730 |
| 731 ////////////////////////////////////////////////////////////////////////////// | 731 ////////////////////////////////////////////////////////////////////////////// |
| 732 | 732 |
| 733 static SkView* MyFactory() { return new SlideView; } | 733 static SkView* MyFactory() { return new SlideView; } |
| 734 static SkViewRegister reg(MyFactory); | 734 static SkViewRegister reg(MyFactory); |
| OLD | NEW |