Chromium Code Reviews| Index: tools/viewer/Viewer.cpp |
| diff --git a/tools/viewer/Viewer.cpp b/tools/viewer/Viewer.cpp |
| index 7dd265e6e2183cd75c4e726410be8a845aa12d41..bf95977122c5c739c2a6098e385fb023abe5925e 100644 |
| --- a/tools/viewer/Viewer.cpp |
| +++ b/tools/viewer/Viewer.cpp |
| @@ -224,10 +224,8 @@ void Viewer::updateMatrix(){ |
| m.postTranslate(cx, cy); |
| } |
| - // TODO: add gesture support |
| - // Apply any gesture matrix |
| - //m.preConcat(fGesture.localM()); |
| - //m.preConcat(fGesture.globalM()); |
| + m.preConcat(fWindow->getGestureLocalM()); |
| + m.preConcat(fWindow->getGestureGlobalM()); |
| fLocalMatrix = m; |
| } |
| @@ -260,6 +258,8 @@ void Viewer::onPaint(SkCanvas* canvas) { |
| drawStats(canvas); |
| } |
| fCommands.drawHelp(canvas); |
| + |
| + updateMatrix(); |
|
djsollen
2016/05/16 18:16:00
comment why we need to update the matrix after we
liyuqian
2016/05/16 18:32:37
Done.
|
| } |
| void Viewer::drawStats(SkCanvas* canvas) { |