Chromium Code Reviews| Index: chrome/browser/ui/views/bar_control_button.cc |
| diff --git a/chrome/browser/ui/views/bar_control_button.cc b/chrome/browser/ui/views/bar_control_button.cc |
| index eecd5186b365e18fd90fc46186759b24c171021b..cef871b2736449854f48a521da4baf2cc109979a 100644 |
| --- a/chrome/browser/ui/views/bar_control_button.cc |
| +++ b/chrome/browser/ui/views/bar_control_button.cc |
| @@ -9,6 +9,7 @@ |
| #include "ui/gfx/vector_icons_public.h" |
| #include "ui/views/animation/button_ink_drop_delegate.h" |
| #include "ui/views/border.h" |
| +#include "ui/views/painter.h" |
| namespace { |
| @@ -25,6 +26,8 @@ BarControlButton::BarControlButton(views::ButtonListener* listener) |
| set_has_ink_drop_action_on_click(true); |
| SetImageAlignment(views::ImageButton::ALIGN_CENTER, |
| views::ImageButton::ALIGN_MIDDLE); |
| + SetFocusPainter(nullptr); |
| + UseMdFocusRing(); |
| } |
| BarControlButton::~BarControlButton() {} |
| @@ -50,6 +53,7 @@ void BarControlButton::OnThemeChanged() { |
| image = gfx::CreateVectorIcon(id_, 16, SkColorSetA(icon_color, 0xff / 2)); |
| SetImage(views::CustomButton::STATE_DISABLED, &image); |
| set_ink_drop_base_color(icon_color); |
| + SizeToPreferredSize(); |
|
sky
2016/03/22 15:31:40
What view has BarControlButton in it? I get nervou
Evan Stade
2016/03/22 17:35:44
infobarview, find bar, download shelf. The alterna
sky
2016/03/22 18:02:27
Doesn't find bar and the like need to relayout in
Evan Stade
2016/03/22 18:16:11
This code path gets hit as soon as BarControlButto
|
| } |
| void BarControlButton::OnNativeThemeChanged(const ui::NativeTheme* theme) { |