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

Side by Side Diff: ash/wm/image_grid.h

Issue 9562038: ui/gfx: Make gfx::Canvas inherit from gfx::CanvasSkia. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more fixes Created 8 years, 9 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ASH_WM_IMAGE_GRID_H_ 5 #ifndef ASH_WM_IMAGE_GRID_H_
6 #define ASH_WM_IMAGE_GRID_H_ 6 #define ASH_WM_IMAGE_GRID_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/gtest_prod_util.h" 10 #include "base/gtest_prod_util.h"
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 class ImagePainter : public ui::LayerDelegate { 129 class ImagePainter : public ui::LayerDelegate {
130 public: 130 public:
131 ImagePainter(const gfx::Image* image) : image_(image) {} 131 ImagePainter(const gfx::Image* image) : image_(image) {}
132 virtual ~ImagePainter() {} 132 virtual ~ImagePainter() {}
133 133
134 // Clips |layer| to |clip_rect|. Triggers a repaint if the clipping 134 // Clips |layer| to |clip_rect|. Triggers a repaint if the clipping
135 // rectangle has changed. An empty rectangle disables clipping. 135 // rectangle has changed. An empty rectangle disables clipping.
136 void SetClipRect(const gfx::Rect& clip_rect, ui::Layer* layer); 136 void SetClipRect(const gfx::Rect& clip_rect, ui::Layer* layer);
137 137
138 // ui::LayerDelegate implementation: 138 // ui::LayerDelegate implementation:
139 virtual void OnPaintLayer(gfx::Canvas* canvas) OVERRIDE; 139 virtual void OnPaintLayer(gfx::CanvasSkia* canvas) OVERRIDE;
140 140
141 private: 141 private:
142 friend class TestAPI; 142 friend class TestAPI;
143 143
144 const gfx::Image* image_; // not owned 144 const gfx::Image* image_; // not owned
145 145
146 gfx::Rect clip_rect_; 146 gfx::Rect clip_rect_;
147 147
148 DISALLOW_COPY_AND_ASSIGN(ImagePainter); 148 DISALLOW_COPY_AND_ASSIGN(ImagePainter);
149 }; 149 };
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 scoped_ptr<ImagePainter> bottom_painter_; 206 scoped_ptr<ImagePainter> bottom_painter_;
207 scoped_ptr<ImagePainter> bottom_right_painter_; 207 scoped_ptr<ImagePainter> bottom_right_painter_;
208 208
209 DISALLOW_COPY_AND_ASSIGN(ImageGrid); 209 DISALLOW_COPY_AND_ASSIGN(ImageGrid);
210 }; 210 };
211 211
212 } // namespace internal 212 } // namespace internal
213 } // namespace ash 213 } // namespace ash
214 214
215 #endif // ASH_WM_IMAGE_GRID_H_ 215 #endif // ASH_WM_IMAGE_GRID_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698