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

Unified Diff: chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm

Issue 1061233004: [Mac] Add "Supervised" and "Accounts for kids" labels in the fast user switcher (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
diff --git a/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm b/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
index 549b13b8542aeebef8661612803cec4fc10f2462..8af9a79ecf338272f0f06aefb1a8b5f1a2fbdcd4 100644
--- a/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
+++ b/chrome/browser/ui/cocoa/profiles/profile_chooser_controller.mm
@@ -1802,7 +1802,17 @@ class ActiveProfileObserverBridge : public AvatarMenuObserver,
initWithFrame:rect
imageTitleSpacing:kImageTitleSpacing
backgroundColor:GetDialogBackgroundColor()]);
- [profileButton setTitle:base::SysUTF16ToNSString(item.name)];
+
+ NSString* title;
+ if (item.legacy_supervised) {
msw 2015/04/14 18:15:12 This general logic seems to be useful for profile_
Marc Treib 2015/04/15 07:47:11 Acknowledged.
+ title = l10n_util::GetNSStringF(IDS_SUPERVISED_USER_NEW_AVATAR_LABEL,
+ item.name);
+ } else if (item.child_account) {
+ title = l10n_util::GetNSStringF(IDS_CHILD_AVATAR_LABEL, item.name);
+ } else {
+ title = base::SysUTF16ToNSString(item.name);
+ }
+ [profileButton setTitle:title];
// Use the low-res, small default avatars in the fast user switcher, like
// we do in the menu bar.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698