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

Unified Diff: ash/common/frame/caption_buttons/frame_caption_button.cc

Issue 2620613005: Move more vector icons to respective directories and update code to (Closed)
Patch Set: Created 3 years, 11 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: ash/common/frame/caption_buttons/frame_caption_button.cc
diff --git a/ash/common/frame/caption_buttons/frame_caption_button.cc b/ash/common/frame/caption_buttons/frame_caption_button.cc
index d496f1b3535d21e4c7c7fc6150d133d26da468aa..74f1ef9021b7730b9562410a2811f3e395458508 100644
--- a/ash/common/frame/caption_buttons/frame_caption_button.cc
+++ b/ash/common/frame/caption_buttons/frame_caption_button.cc
@@ -56,9 +56,10 @@ FrameCaptionButton::~FrameCaptionButton() {}
void FrameCaptionButton::SetImage(CaptionButtonIcon icon,
Animate animate,
- gfx::VectorIconId icon_image_id) {
+ const gfx::VectorIcon& icon_definition) {
gfx::ImageSkia new_icon_image = gfx::CreateVectorIcon(
- icon_image_id, use_light_images_ ? SK_ColorWHITE : gfx::kChromeIconGrey);
+ icon_definition,
+ use_light_images_ ? SK_ColorWHITE : gfx::kChromeIconGrey);
// The early return is dependent on |animate| because callers use SetImage()
// with ANIMATE_NO to progress the crossfade animation to the end.
@@ -72,7 +73,7 @@ void FrameCaptionButton::SetImage(CaptionButtonIcon icon,
crossfade_icon_image_ = icon_image_;
icon_ = icon;
- icon_image_id_ = icon_image_id;
+ icon_definition_ = &icon_definition;
icon_image_ = new_icon_image;
if (animate == ANIMATE_YES) {

Powered by Google App Engine
This is Rietveld 408576698