Index: chrome/browser/ui/views/frame/browser_view.cc |
diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc |
index 6c5227623f475ccc76a017bdae277ab60fe43078..073cd8013060db69728e255ddc764fd1f4d2a428 100644 |
--- a/chrome/browser/ui/views/frame/browser_view.cc |
+++ b/chrome/browser/ui/views/frame/browser_view.cc |
@@ -2573,9 +2573,19 @@ void BrowserView::ShowAvatarBubble(WebContents* web_contents, |
} |
void BrowserView::ShowAvatarBubbleFromAvatarButton() { |
- AvatarMenuButton* button = frame_->GetAvatarMenuButton(); |
- if (button) |
- button->ShowAvatarBubble(); |
+ if (CommandLine::ForCurrentProcess()->HasSwitch( |
noms (inactive)
2013/11/04 22:03:42
If browser_view can use things from profiles, you
Roger Tawa OOO till Jul 10th
2013/11/04 22:10:50
Done.
|
+ switches::kNewProfileManagement)) { |
+ NewAvatarButton* button = frame_->GetNewAvatarMenuButton(); |
+ if (button) { |
+ ui::MouseEvent mouse_event(ui::ET_MOUSE_RELEASED, gfx::Point(), |
+ gfx::Point(), ui::EF_LEFT_MOUSE_BUTTON); |
+ button->OnMouseReleased(mouse_event); |
Roger Tawa OOO till Jul 10th
2013/11/04 22:01:22
Is there a better way to programmatically trigger
|
+ } |
+ } else { |
+ AvatarMenuButton* button = frame_->GetAvatarMenuButton(); |
+ if (button) |
+ button->ShowAvatarBubble(); |
+ } |
} |
void BrowserView::ShowPasswordGenerationBubble( |