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

Side by Side Diff: samplecode/GMSampleView.h

Issue 894083003: add SkAnimTimer, SPACE = pause/resume, ESP = stop (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 10 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
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 8
9 9
10 #ifndef GMSampleView_DEFINED 10 #ifndef GMSampleView_DEFINED
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 SkPaint paint; 63 SkPaint paint;
64 paint.setColor(0x40FF8833); 64 paint.setColor(0x40FF8833);
65 canvas->drawRect(r, paint); 65 canvas->drawRect(r, paint);
66 } 66 }
67 } 67 }
68 68
69 virtual void onDrawBackground(SkCanvas* canvas) { 69 virtual void onDrawBackground(SkCanvas* canvas) {
70 fGM->drawBackground(canvas); 70 fGM->drawBackground(canvas);
71 } 71 }
72 72
73 bool onAnimatePulse(SkMSec curr, SkMSec prev) SK_OVERRIDE { 73 bool onAnimate(const SkAnimTimer& timer) SK_OVERRIDE {
74 return fGM->animatePulse(curr, prev); 74 return fGM->animate(timer);
75 } 75 }
76 76
77 private: 77 private:
78 GM* fGM; 78 GM* fGM;
79 typedef SampleView INHERITED; 79 typedef SampleView INHERITED;
80 }; 80 };
81 81
82 #endif 82 #endif
OLDNEW
« gm/SkAnimTimer.h ('K') | « gm/gm.cpp ('k') | samplecode/SampleAnimBlur.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698