| Index: views/painter.cc
|
| ===================================================================
|
| --- views/painter.cc (revision 50661)
|
| +++ views/painter.cc (working copy)
|
| @@ -7,6 +7,7 @@
|
| #include "app/resource_bundle.h"
|
| #include "base/logging.h"
|
| #include "gfx/canvas.h"
|
| +#include "gfx/canvas_skia.h"
|
| #include "gfx/insets.h"
|
| #include "third_party/skia/include/core/SkBitmap.h"
|
| #include "third_party/skia/include/effects/SkGradientShader.h"
|
| @@ -43,8 +44,9 @@
|
| // Need to unref shader, otherwise never deleted.
|
| s->unref();
|
|
|
| - canvas->drawRectCoords(SkIntToScalar(0), SkIntToScalar(0),
|
| - SkIntToScalar(w), SkIntToScalar(h), paint);
|
| + canvas->AsCanvasSkia()->drawRectCoords(
|
| + SkIntToScalar(0), SkIntToScalar(0), SkIntToScalar(w), SkIntToScalar(h),
|
| + paint);
|
| }
|
|
|
| private:
|
| @@ -146,10 +148,10 @@
|
| DCHECK(canvas && painter);
|
| if (w < 0 || h < 0)
|
| return;
|
| - canvas->save();
|
| + canvas->AsCanvasSkia()->save();
|
| canvas->TranslateInt(x, y);
|
| painter->Paint(w, h, canvas);
|
| - canvas->restore();
|
| + canvas->AsCanvasSkia()->restore();
|
| }
|
|
|
| // static
|
|
|