SampleAAGeometry tweaks

- Use capital letters avoid conflict with built-in commands,
  particularly zoom-window ('z') and toggle-backend ('d').
- Increase kHitToleranace for touch screens.

Bug: skia:
Change-Id: I6feaabd8aa06600bdeb4623ab081d973369c4841
Reviewed-on: https://skia-review.googlesource.com/52528
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Reviewed-by: Cary Clark <caryclark@google.com>
This commit is contained in:
Chris Dalton 2017-10-20 11:46:47 -06:00 committed by Skia Commit-Bot
parent 11d5236c5a
commit 08d1a25073

View File

@ -815,7 +815,7 @@ class AAGeometryView : public SampleView {
bool fHandlePathMove;
bool fShowLegend;
bool fHideAll;
const int kHitToleranace = 5;
const int kHitToleranace = 25;
public:
@ -1807,10 +1807,10 @@ static struct KeyCommand {
{ ' ', 0, "space", "center path", &AAGeometryView::scaleToFit },
{ '-', 0, "-", "zoom out", &AAGeometryView::scaleDown },
{ '+', '=', "+/=", "zoom in", &AAGeometryView::scaleUp },
{ 'd', 0, "d", "dump to console", &AAGeometryView::pathDump },
{ 'h', 0, "h", "hide controls", &AAGeometryView::hideAll },
{ 'r', 0, "r", "reset path", &AAGeometryView::constructPath },
{ 'z', 0, "z", "undo", &AAGeometryView::undo },
{ 'D', 0, "D", "dump to console", &AAGeometryView::pathDump },
{ 'H', 0, "H", "hide controls", &AAGeometryView::hideAll },
{ 'R', 0, "R", "reset path", &AAGeometryView::constructPath },
{ 'Z', 0, "Z", "undo", &AAGeometryView::undo },
{ '?', 0, "?", "show legend", &AAGeometryView::showLegend },
};