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

Unified Diff: chrome/browser/ui/views/location_bar/location_bar_view.cc

Issue 8359029: ui/gfx: Convert Canvas::DrawFocusRect() to use gfx::Rect. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address Peter's review 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: chrome/browser/ui/views/location_bar/location_bar_view.cc
diff --git a/chrome/browser/ui/views/location_bar/location_bar_view.cc b/chrome/browser/ui/views/location_bar/location_bar_view.cc
index aefe220ff8b14ffeb1bba68c4cc8f09b98de16a6..993e9ac03cac78159bded1d7478b6386cff38ea9 100644
--- a/chrome/browser/ui/views/location_bar/location_bar_view.cc
+++ b/chrome/browser/ui/views/location_bar/location_bar_view.cc
@@ -755,10 +755,11 @@ void LocationBarView::OnPaint(gfx::Canvas* canvas) {
if (show_focus_rect_ && HasFocus()) {
gfx::Rect r = location_entry_view_->bounds();
#if defined(OS_WIN)
- canvas->DrawFocusRect(r.x() - 1, r.y() - 1, r.width() + 2, r.height() + 2);
+ r.Inset(-1, -1);
#else
- canvas->DrawFocusRect(r.x() - 1, r.y(), r.width() + 2, r.height());
+ r.Inset(-1, 0);
#endif
+ canvas->DrawFocusRect(r);
}
}
« no previous file with comments | « chrome/browser/ui/views/download/download_shelf_view.cc ('k') | chrome/browser/ui/views/tabs/dragged_tab_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698