Chromium Code Reviews| Index: chrome/browser/ui/views/profiles/avatar_menu_bubble_view.cc |
| diff --git a/chrome/browser/ui/views/profiles/avatar_menu_bubble_view.cc b/chrome/browser/ui/views/profiles/avatar_menu_bubble_view.cc |
| index aa3b695147aa85ca215b3e0b86f10069d11cea3d..5f48429eb21a124ffa0c84327ab5a4aa0811080a 100644 |
| --- a/chrome/browser/ui/views/profiles/avatar_menu_bubble_view.cc |
| +++ b/chrome/browser/ui/views/profiles/avatar_menu_bubble_view.cc |
| @@ -260,10 +260,14 @@ ProfileItemView::ProfileItemView(const AvatarMenu::Item& item, |
| image_view_ = new ProfileImageView(); |
| gfx::ImageSkia profile_icon = *item_.icon.ToImageSkia(); |
| - if (item_.active || item_.signin_required) |
| + if (item_.active || item_.signin_required) { |
| image_view_->SetImage(GetBadgedIcon(profile_icon)); |
| - else |
| - image_view_->SetImage(profile_icon); |
| + } else { |
| + // GetSizedAvatarIcon will resize the icon in case it's too large |
| + image_view_->SetImage(profiles::GetSizedAvatarIcon( |
|
msw
2014/04/25 19:50:45
The ImageView class comment says "If a size is pro
Mike Lerman
2014/04/28 13:21:26
Done.
|
| + item_.icon, false, profiles::kAvatarIconWidth, kItemHeight). |
| + ToImageSkia()); |
|
msw
2014/04/29 19:25:46
nit: I think this ought to be indented four more s
Mike Lerman
2014/04/29 20:56:57
Done.
|
| + } |
| AddChildView(image_view_); |
| // Add a label to show the profile name. |