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

Unified Diff: ui/views/controls/menu/menu_separator.cc

Issue 2813703003: Use NativeTheme to draw vertical menu separators. (Closed)
Patch Set: use rectf Created 3 years, 8 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/native_theme/native_theme_win.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/menu/menu_separator.cc
diff --git a/ui/views/controls/menu/menu_separator.cc b/ui/views/controls/menu/menu_separator.cc
index d3d532e2fb5d7f6d75232bc207845dda4e276378..297833a6d0d3f4920d76f933c2525d78fc99eeb4 100644
--- a/ui/views/controls/menu/menu_separator.cc
+++ b/ui/views/controls/menu/menu_separator.cc
@@ -52,9 +52,9 @@ void MenuSeparator::OnPaint(gfx::Canvas* canvas) {
ui::NativeTheme::ExtraParams params;
params.menu_separator.paint_rect = &paint_rect;
params.menu_separator.type = type_;
- GetNativeTheme()->Paint(
- canvas->sk_canvas(), ui::NativeTheme::kMenuPopupSeparator,
- ui::NativeTheme::kNormal, gfx::Rect(bounds().size()), params);
+ GetNativeTheme()->Paint(canvas->sk_canvas(),
+ ui::NativeTheme::kMenuPopupSeparator,
+ ui::NativeTheme::kNormal, GetLocalBounds(), params);
}
gfx::Size MenuSeparator::GetPreferredSize() const {
« no previous file with comments | « ui/native_theme/native_theme_win.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698