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

Unified Diff: ui/gfx/canvas_paint_mac.mm

Issue 2640983002: Rename paint data structures (Closed)
Patch Set: DrawingDisplayItem Created 3 years, 11 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
« no previous file with comments | « ui/gfx/canvas.cc ('k') | ui/gfx/canvas_skia.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/canvas_paint_mac.mm
diff --git a/ui/gfx/canvas_paint_mac.mm b/ui/gfx/canvas_paint_mac.mm
index 73ed62abc6c348be272fb96c967c4a98454975ea..ab7dda216fdf965ff89b9ad90a3a8997b2ec1a60 100644
--- a/ui/gfx/canvas_paint_mac.mm
+++ b/ui/gfx/canvas_paint_mac.mm
@@ -23,11 +23,13 @@ CanvasSkiaPaint::CanvasSkiaPaint(NSRect dirtyRect, bool opaque)
CanvasSkiaPaint::~CanvasSkiaPaint() {
if (!is_empty()) {
- SkCanvas* canvas = sk_canvas();
+ cc::PaintCanvas* canvas = sk_canvas();
canvas->restoreToCount(1);
// Blit the dirty rect to the current context.
SkPixmap pixmap;
+ // TODO(enne): make this class record directly into a bitmap and
+ // remove this peekPixels call.
bool success = canvas->peekPixels(&pixmap);
DCHECK(success);
SkBitmap bitmap;
@@ -68,7 +70,7 @@ void CanvasSkiaPaint::Init(bool opaque) {
gfx::Size size(NSWidth(rectangle_), NSHeight(rectangle_));
RecreateBackingCanvas(size, scale, opaque);
- SkCanvas* canvas = sk_canvas();
+ cc::PaintCanvas* canvas = sk_canvas();
canvas->clear(SkColorSetARGB(0, 0, 0, 0));
// Need to translate so that the dirty region appears at the origin of the
« no previous file with comments | « ui/gfx/canvas.cc ('k') | ui/gfx/canvas_skia.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698