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

Issue 171523004: Stop using the old-style profile names when using --new-profile-management (Closed)

Created:
6 years, 10 months ago by noms (inactive)
Modified:
6 years, 10 months ago
CC:
chromium-reviews, tfarina, rginda+watch_chromium.org, yoshiki+watch_chromium.org
Visibility:
Public.

Description

Stop using the old-style profile names when using --new-profile-management Instead use: - "You" for a single, local profile - The custom name chosen by the user, if the user renames the profile - The user's GAIA first name for signed in profiles - Person %n in all other cases. This will be used consistently in both by the avatar menu button, and the avatar bubble. Bonus changes to make this work: - changed the name and signature of profiles::GetActiveProfileDisplayName to GetAvatarNameForProfile, to make sure it's not accidentally used outside of the avatar button related stuff, with baffling results ("Why is the profile name 'You'?) - the Win avatar button now listens to ProfileInfoCache changes (just like the Mac one does), so that if a new profile is added, the avatar button changes from displaying 'You' to the actual profile name. BUG=312352 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=253588

Patch Set 1 : #

Patch Set 2 : whitespace #

Total comments: 13

Patch Set 3 : review comments #

Total comments: 2

Patch Set 4 : fix sscanf import #

Patch Set 5 : moved new tests behind no-android/no-cros ifdef #

Unified diffs Side-by-side diffs Delta from patch set Stats (+243 lines, -48 lines) Patch
M chrome/app/generated_resources.grd View 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/browser/profiles/profile_info_cache.cc View 3 chunks +9 lines, -1 line 0 comments Download
M chrome/browser/profiles/profile_manager.cc View 1 2 1 chunk +4 lines, -1 line 0 comments Download
M chrome/browser/profiles/profile_manager_unittest.cc View 1 2 3 4 7 chunks +140 lines, -14 lines 0 comments Download
M chrome/browser/profiles/profiles_state.h View 1 2 1 chunk +5 lines, -2 lines 0 comments Download
M chrome/browser/profiles/profiles_state.cc View 1 2 3 2 chunks +31 lines, -7 lines 0 comments Download
M chrome/browser/ui/cocoa/browser/avatar_button_controller.mm View 1 2 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/cocoa/browser/profile_chooser_controller.mm View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/ui/views/frame/browser_non_client_frame_view.cc View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/new_avatar_button.h View 1 2 2 chunks +16 lines, -6 lines 0 comments Download
M chrome/browser/ui/views/new_avatar_button.cc View 1 2 3 chunks +23 lines, -8 lines 0 comments Download
M chrome/browser/ui/views/profile_chooser_view.cc View 1 2 2 chunks +4 lines, -5 lines 0 comments Download

Messages

Total messages: 27 (0 generated)
noms (inactive)
Hi all, As part of the profile management redesign, we're changing a little what the ...
6 years, 10 months ago (2014-02-20 19:32:41 UTC) #1
groby-ooo-7-16
Cocoa LGTM, 2 nits https://codereview.chromium.org/171523004/diff/100001/chrome/browser/profiles/profile_manager_unittest.cc File chrome/browser/profiles/profile_manager_unittest.cc (right): https://codereview.chromium.org/171523004/diff/100001/chrome/browser/profiles/profile_manager_unittest.cc#newcode137 chrome/browser/profiles/profile_manager_unittest.cc:137: ProfileInfoCache& cache = profile_manager->GetProfileInfoCache(); Indent ...
6 years, 10 months ago (2014-02-20 20:17:27 UTC) #2
rpetterson
https://codereview.chromium.org/171523004/diff/100001/chrome/browser/profiles/profile_manager_unittest.cc File chrome/browser/profiles/profile_manager_unittest.cc (right): https://codereview.chromium.org/171523004/diff/100001/chrome/browser/profiles/profile_manager_unittest.cc#newcode1036 chrome/browser/profiles/profile_manager_unittest.cc:1036: // We should display custom names for local profiles. ...
6 years, 10 months ago (2014-02-20 21:41:32 UTC) #3
sky
LGTM https://codereview.chromium.org/171523004/diff/100001/chrome/browser/ui/views/new_avatar_button.h File chrome/browser/ui/views/new_avatar_button.h (right): https://codereview.chromium.org/171523004/diff/100001/chrome/browser/ui/views/new_avatar_button.h#newcode38 chrome/browser/ui/views/new_avatar_button.h:38: nit: no newline between overrides for same class ...
6 years, 10 months ago (2014-02-20 22:14:07 UTC) #4
noms (inactive)
I've addressed the comments, and added in two tiny changes. Unfortunately, I also accidentally rebased, ...
6 years, 10 months ago (2014-02-24 22:35:05 UTC) #5
rpetterson
lgtm
6 years, 10 months ago (2014-02-24 23:50:18 UTC) #6
rpetterson
Oh, one additional thought (but doesn't change my lgtm). https://codereview.chromium.org/171523004/diff/260001/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/171523004/diff/260001/chrome/browser/profiles/profile_manager.cc#newcode1118 chrome/browser/profiles/profile_manager.cc:1118: ...
6 years, 10 months ago (2014-02-24 23:50:43 UTC) #7
sky
SLGTM
6 years, 10 months ago (2014-02-25 00:36:45 UTC) #8
noms (inactive)
Thanks everyone! :) https://codereview.chromium.org/171523004/diff/260001/chrome/browser/profiles/profile_manager.cc File chrome/browser/profiles/profile_manager.cc (right): https://codereview.chromium.org/171523004/diff/260001/chrome/browser/profiles/profile_manager.cc#newcode1118 chrome/browser/profiles/profile_manager.cc:1118: // the new state and away ...
6 years, 10 months ago (2014-02-25 01:08:26 UTC) #9
noms (inactive)
The CQ bit was checked by noms@chromium.org
6 years, 10 months ago (2014-02-25 01:08:52 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/260001
6 years, 10 months ago (2014-02-25 01:56:25 UTC) #11
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 10 months ago (2014-02-25 02:52:52 UTC) #12
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) app_list_unittests, ash_unittests, aura_unittests, cacheinvalidation_unittests, cc_unittests, check_deps, ...
6 years, 10 months ago (2014-02-25 02:52:53 UTC) #13
noms (inactive)
The CQ bit was checked by noms@chromium.org
6 years, 10 months ago (2014-02-25 20:47:30 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/280001
6 years, 10 months ago (2014-02-25 20:50:28 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/280001
6 years, 10 months ago (2014-02-25 21:59:16 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/280001
6 years, 10 months ago (2014-02-25 22:25:54 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/280001
6 years, 10 months ago (2014-02-25 23:33:38 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/280001
6 years, 10 months ago (2014-02-26 00:17:38 UTC) #19
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 10 months ago (2014-02-26 05:21:11 UTC) #20
commit-bot: I haz the power
Retried try job too often on android_dbg for step(s) slave_steps http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=android_dbg&number=154336
6 years, 10 months ago (2014-02-26 05:21:11 UTC) #21
noms (inactive)
The CQ bit was checked by noms@chromium.org
6 years, 10 months ago (2014-02-26 14:47:40 UTC) #22
noms (inactive)
The CQ bit was unchecked by noms@chromium.org
6 years, 10 months ago (2014-02-26 14:47:50 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/280001
6 years, 10 months ago (2014-02-26 14:48:10 UTC) #24
noms (inactive)
The CQ bit was checked by noms@chromium.org
6 years, 10 months ago (2014-02-26 16:57:37 UTC) #25
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/noms@chromium.org/171523004/320001
6 years, 10 months ago (2014-02-26 16:59:17 UTC) #26
commit-bot: I haz the power
6 years, 10 months ago (2014-02-26 20:39:30 UTC) #27
Message was sent while issue was closed.
Change committed as 253588

Powered by Google App Engine
This is Rietveld 408576698