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

Unified Diff: tools/viewer/Viewer.h

Issue 2004633002: Add drawer with state information (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Format_old Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: tools/viewer/Viewer.h
diff --git a/tools/viewer/Viewer.h b/tools/viewer/Viewer.h
index 0bafee175ba8b7d1165e3057dbb0495af2d075a4..2551ca977f81ff0130ecc59e68b4772621c93abe 100644
--- a/tools/viewer/Viewer.h
+++ b/tools/viewer/Viewer.h
@@ -8,12 +8,15 @@
#ifndef Viewer_DEFINED
#define Viewer_DEFINED
+#include <string>
+
#include "sk_app/Application.h"
#include "sk_app/CommandSet.h"
#include "sk_app/Window.h"
#include "gm.h"
#include "SkAnimTimer.h"
#include "Slide.h"
+#include "SkJSONCPP.h"
class SkCanvas;
@@ -25,12 +28,15 @@ public:
void onPaint(SkCanvas* canvas);
void onIdle(double ms) override;
bool onTouch(int owner, sk_app::Window::InputState state, float x, float y);
+ void onSet(const SkString& stateName, const SkString& stateValue);
private:
void initSlides();
void updateTitle();
void setupCurrentSlide(int previousSlide);
+ Json::Value getStateJson() const;
+
void drawStats(SkCanvas* canvas);
void changeZoomLevel(float delta);

Powered by Google App Engine
This is Rietveld 408576698