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

Unified Diff: views/controls/combobox/native_combobox_views.cc

Issue 8383028: ui/gfx: Convert Canvas::ClipRectInt() to use gfx::Rect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 2 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
Index: views/controls/combobox/native_combobox_views.cc
diff --git a/views/controls/combobox/native_combobox_views.cc b/views/controls/combobox/native_combobox_views.cc
index 44c6838e7aa9f4f61f6615faffef261d8502dc65..6a3950985e4e97472e46d78e36da6c966b55584f 100644
--- a/views/controls/combobox/native_combobox_views.cc
+++ b/views/controls/combobox/native_combobox_views.cc
@@ -302,8 +302,10 @@ void NativeComboboxViews::PaintText(gfx::Canvas* canvas) {
gfx::Insets insets = GetInsets();
canvas->Save();
- canvas->ClipRectInt(insets.left(), insets.top(),
- width() - insets.width(), height() - insets.height());
+ canvas->ClipRectInt(gfx::Rect(insets.left(),
Peter Kasting 2011/10/25 20:24:47 Nit: I think you can just pass GetContentsBounds()
tfarina 2011/10/25 23:52:41 Done.
+ insets.top(),
+ width() - insets.width(),
+ height() - insets.height()));
int x = insets.left();
int y = insets.top();

Powered by Google App Engine
This is Rietveld 408576698