StatisticsLayer was shifting subsequent paints.

Turns out we weren't actually saving and restoring the matrix, so our
combined 180.0 pixel downshift was also affecting all subsequent
paints in the frame.
This commit is contained in:
Ian Hickson 2016-01-10 15:11:11 -08:00
parent 59c075786a
commit 455ceab5f9

View File

@ -66,7 +66,7 @@ void StatisticsLayer::Paint(PaintContext::ScopedFrame& frame) {
using Opt = CompositorOptions::Option;
SkScalar width = has_paint_bounds() ? paint_bounds().width() : 0;
SkAutoCanvasRestore save(&frame.canvas(), false);
SkAutoCanvasRestore save(&frame.canvas(), true);
VisualizeStopWatch(frame.canvas(), frame.context().frame_time(), width,
options_.isEnabled(Opt::VisualizeRasterizerStatistics),