Commit 838e9d27 authored by Peter Boström's avatar Peter Boström Committed by Commit Bot

Use themed vector icon as avatar placeholder

Replaces the png graphics that blends into the default-color highlight
effect.

Bug: chromium:978388

Change-Id: I33e63b1e15c225761f6f089aac5e853463169b9a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1736440Reviewed-by: default avatarThomas Tangl <tangltom@chromium.org>
Commit-Queue: Peter Boström <pbos@chromium.org>
Cr-Commit-Position: refs/heads/master@{#684401}
parent b45ec874
...@@ -326,6 +326,12 @@ bool AvatarToolbarButton::ShouldShowGenericIcon() const { ...@@ -326,6 +326,12 @@ bool AvatarToolbarButton::ShouldShowGenericIcon() const {
// This can happen if the user deletes the current profile. // This can happen if the user deletes the current profile.
return true; return true;
} }
// If the profile is using the placeholder avatar, fall back on the themeable
// vector icon instead.
if (entry->GetAvatarIconIndex() == profiles::GetPlaceholderAvatarIndex())
return true;
return entry->GetAvatarIconIndex() == 0 && return entry->GetAvatarIconIndex() == 0 &&
g_browser_process->profile_manager() g_browser_process->profile_manager()
->GetProfileAttributesStorage() ->GetProfileAttributesStorage()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment