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

Unified Diff: chrome/browser/profiles/avatar_menu_desktop.cc

Issue 1972033002: Simplify some old avatar menu button code. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: reinstate ash browser test fix Created 4 years, 7 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 | « chrome/browser/profiles/avatar_menu.h ('k') | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/profiles/avatar_menu_desktop.cc
diff --git a/chrome/browser/profiles/avatar_menu_desktop.cc b/chrome/browser/profiles/avatar_menu_desktop.cc
index 8a7bca6a7ced30c2bf08e199e18386a07c333a4a..225122b933e239d152cfa58cef0517731b568101 100644
--- a/chrome/browser/profiles/avatar_menu_desktop.cc
+++ b/chrome/browser/profiles/avatar_menu_desktop.cc
@@ -16,12 +16,11 @@
// static
void AvatarMenu::GetImageForMenuButton(const base::FilePath& profile_path,
- gfx::Image* image,
- bool* is_rectangle) {
+ gfx::Image* image) {
ProfileAttributesEntry* entry;
if (!g_browser_process->profile_manager()->GetProfileAttributesStorage().
GetProfileAttributesWithPath(profile_path, &entry)) {
- NOTREACHED();
+ // This can happen if the user deletes the current profile.
return;
}
@@ -30,7 +29,6 @@ void AvatarMenu::GetImageForMenuButton(const base::FilePath& profile_path,
const gfx::Image* gaia_image = entry->GetGAIAPicture();
if (gaia_image) {
*image = *gaia_image;
- *is_rectangle = true;
return;
}
}
@@ -40,5 +38,4 @@ void AvatarMenu::GetImageForMenuButton(const base::FilePath& profile_path,
const int resource_id =
profiles::GetDefaultAvatarIconResourceIDAtIndex(icon_index);
*image = ResourceBundle::GetSharedInstance().GetNativeImageNamed(resource_id);
- *is_rectangle = false;
}
« no previous file with comments | « chrome/browser/profiles/avatar_menu.h ('k') | chrome/browser/ui/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698