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

Side by Side Diff: ui/gfx/canvas.h

Issue 8383028: ui/gfx: Convert Canvas::ClipRectInt() to use gfx::Rect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix typo Created 9 years, 1 month 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
« no previous file with comments | « chrome/browser/ui/views/tabs/base_tab.cc ('k') | ui/gfx/canvas_direct2d.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 UI_GFX_CANVAS_H_ 5 #ifndef UI_GFX_CANVAS_H_
6 #define UI_GFX_CANVAS_H_ 6 #define UI_GFX_CANVAS_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 virtual void SaveLayerAlpha(uint8 alpha) = 0; 95 virtual void SaveLayerAlpha(uint8 alpha) = 0;
96 virtual void SaveLayerAlpha(uint8 alpha, const gfx::Rect& layer_bounds) = 0; 96 virtual void SaveLayerAlpha(uint8 alpha, const gfx::Rect& layer_bounds) = 0;
97 97
98 // Restores the drawing state after a call to Save*(). It is an error to 98 // Restores the drawing state after a call to Save*(). It is an error to
99 // call Restore() more times than Save*(). 99 // call Restore() more times than Save*().
100 virtual void Restore() = 0; 100 virtual void Restore() = 0;
101 101
102 // Wrapper function that takes integer arguments. 102 // Wrapper function that takes integer arguments.
103 // Returns true if the clip is non-empty. 103 // Returns true if the clip is non-empty.
104 // See clipRect for specifics. 104 // See clipRect for specifics.
105 virtual bool ClipRectInt(int x, int y, int w, int h) = 0; 105 virtual bool ClipRectInt(const gfx::Rect& rect) = 0;
106 106
107 // Wrapper function that takes integer arguments. 107 // Wrapper function that takes integer arguments.
108 // See translate() for specifics. 108 // See translate() for specifics.
109 virtual void TranslateInt(int x, int y) = 0; 109 virtual void TranslateInt(int x, int y) = 0;
110 110
111 // Wrapper function that takes integer arguments. 111 // Wrapper function that takes integer arguments.
112 // See scale() for specifics. 112 // See scale() for specifics.
113 virtual void ScaleInt(int x, int y) = 0; 113 virtual void ScaleInt(int x, int y) = 0;
114 114
115 // Fills the specified region with the specified color using a transfer 115 // Fills the specified region with the specified color using a transfer
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 // Returns the rectangle that is invalid. 253 // Returns the rectangle that is invalid.
254 virtual gfx::Rect GetInvalidRect() const = 0; 254 virtual gfx::Rect GetInvalidRect() const = 0;
255 255
256 // Returns the underlying Canvas. 256 // Returns the underlying Canvas.
257 virtual Canvas* AsCanvas() = 0; 257 virtual Canvas* AsCanvas() = 0;
258 }; 258 };
259 259
260 } // namespace gfx; 260 } // namespace gfx;
261 261
262 #endif // UI_GFX_CANVAS_H_ 262 #endif // UI_GFX_CANVAS_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/tabs/base_tab.cc ('k') | ui/gfx/canvas_direct2d.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698