Index: chrome/browser/ui/views/toolbar/app_menu_button.cc |
diff --git a/chrome/browser/ui/views/toolbar/app_menu_button.cc b/chrome/browser/ui/views/toolbar/app_menu_button.cc |
index ca12f2f1d1dd190b9bbe03d43558d92d344fc758..33e7a8fdef34a627863b13f7bdd310e953eed6b6 100644 |
--- a/chrome/browser/ui/views/toolbar/app_menu_button.cc |
+++ b/chrome/browser/ui/views/toolbar/app_menu_button.cc |
@@ -134,6 +134,7 @@ void AppMenuButton::ScheduleAppMenuIconPaint() { |
void AppMenuButton::UpdateIcon() { |
DCHECK(ui::MaterialDesignController::IsModeMaterial()); |
+ gfx::VectorIconId icon_id = gfx::VectorIconId::BROWSER_TOOLS; |
SkColor color = gfx::kPlaceholderColor; |
switch (severity_) { |
case AppMenuIconPainter::SEVERITY_NONE: |
@@ -142,17 +143,19 @@ void AppMenuButton::UpdateIcon() { |
break; |
case AppMenuIconPainter::SEVERITY_LOW: |
color = gfx::kGoogleGreen700; |
+ icon_id = gfx::VectorIconId::UPDATE_MENU_SEVERITY_LOW; |
break; |
case AppMenuIconPainter::SEVERITY_MEDIUM: |
color = gfx::kGoogleYellow700; |
+ icon_id = gfx::VectorIconId::UPDATE_MENU_SEVERITY_MEDIUM; |
break; |
case AppMenuIconPainter::SEVERITY_HIGH: |
color = gfx::kGoogleRed700; |
+ icon_id = gfx::VectorIconId::UPDATE_MENU_SEVERITY_HIGH; |
break; |
} |
kylix_rd
2016/05/10 14:20:10
TODO: Determine other state information to select
Evan Stade
2016/05/10 16:48:14
You're assuming the menu is changing color due to
kylix_rd
2016/05/10 17:49:01
The AppMenuBadgeController doesn't update the Badg
Evan Stade
2016/05/10 18:04:13
I suppose it must, or the logic of mapping state t
kylix_rd
2016/05/10 18:10:51
I've arrived at the same conclusion. A subsequent
Evan Stade
2016/05/10 18:48:39
no. First step would be to see if designers actual
kylix_rd
2016/05/10 19:17:02
Ah, so the question was more rhetorical and specul
|
- SetImage(views::Button::STATE_NORMAL, |
- gfx::CreateVectorIcon(gfx::VectorIconId::BROWSER_TOOLS, color)); |
+ SetImage(views::Button::STATE_NORMAL, gfx::CreateVectorIcon(icon_id, color)); |
kylix_rd
2016/05/10 16:23:47
In seems that calling this gfx::CreateVectorIcon()
Evan Stade
2016/05/10 16:48:14
hardcode a value (16)
kylix_rd
2016/05/10 17:49:01
Done.
|
} |
void AppMenuButton::SetTrailingMargin(int margin) { |