From c7027ab03f2e8bab4c74bc1b047642622d3d682b Mon Sep 17 00:00:00 2001 From: jvanverth Date: Thu, 16 Jun 2016 09:52:35 -0700 Subject: Add samples to Viewer. This adds support with animation, assuming the sample has implemented onAnimate. Event handling has not been implemented. BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2056343004 Committed: https://skia.googlesource.com/skia/+/76963e73704a42a18c29d6fbdcccb566e5c67658 Review-Url: https://codereview.chromium.org/2056343004 --- samplecode/SampleAtlas.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'samplecode/SampleAtlas.cpp') diff --git a/samplecode/SampleAtlas.cpp b/samplecode/SampleAtlas.cpp index 7cf1bb3761..3daf312f6a 100644 --- a/samplecode/SampleAtlas.cpp +++ b/samplecode/SampleAtlas.cpp @@ -232,9 +232,11 @@ protected: void onDrawContent(SkCanvas* canvas) override { canvas->drawDrawable(fDrawable); - this->inval(nullptr); } + bool onAnimate(const SkAnimTimer&) override { + return true; + } #if 0 // TODO: switch over to use this for our animation bool onAnimate(const SkAnimTimer& timer) override { -- cgit v1.2.3