| Index: chrome/browser/ui/cocoa/profiles/avatar_base_controller.mm
|
| diff --git a/chrome/browser/ui/cocoa/profiles/avatar_base_controller.mm b/chrome/browser/ui/cocoa/profiles/avatar_base_controller.mm
|
| index 00cb1b3f3749e889836d8ca0177f7f2a825c3f0a..12ee05210f9fa8a014904a84cb7c135ca55b4aec 100644
|
| --- a/chrome/browser/ui/cocoa/profiles/avatar_base_controller.mm
|
| +++ b/chrome/browser/ui/cocoa/profiles/avatar_base_controller.mm
|
| @@ -188,6 +188,14 @@ class ProfileInfoUpdateObserver : public ProfileInfoCacheObserver,
|
| profiles::TutorialMode tutorialMode;
|
| profiles::BubbleViewModeFromAvatarBubbleMode(
|
| mode, &viewMode, &tutorialMode);
|
| + // Don't start creating the view if it would be an empty fast user switcher.
|
| + // This is the case when there is 0 or 1 profiles (the current one). It has
|
| + // to happen here to prevent the creation of an empty container.
|
| + if (viewMode == profiles::BUBBLE_VIEW_MODE_FAST_PROFILE_CHOOSER &&
|
| + g_browser_process->profile_manager()->GetNumberOfProfiles() <= 1) {
|
| + return;
|
| + }
|
| +
|
| menuController_ =
|
| [[ProfileChooserController alloc] initWithBrowser:browser_
|
| anchoredAt:point
|
|
|