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

Unified Diff: chrome/browser/ui/views/frame/browser_view.cc

Issue 1136693002: Chrome user menu shouldn't close if a tab steals focus (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Chrome user menu shouldn't close if a tab steals focus Created 5 years, 7 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
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 b6db9162491692b96bb85026eb5b1971340b86c4..b0a59db05ae46b1bfff944f2d40e789e6e6a591a 100644
--- a/chrome/browser/ui/views/frame/browser_view.cc
+++ b/chrome/browser/ui/views/frame/browser_view.cc
@@ -2508,6 +2508,16 @@ void BrowserView::ShowAvatarBubbleFromAvatarButton(
ProfileMetrics::LogProfileOpenMethod(ProfileMetrics::ICON_AVATAR_BUBBLE);
}
+void BrowserView::CloseAvatarBubbleFromAvatarButton() {
+ if (switches::IsNewAvatarMenu()) {
Roger Tawa OOO till Jul 10th 2015/05/14 18:55:03 The check for switches::IsNewAvatarMenu() is missi
gogerald1 2015/05/14 21:35:22 Can't, since both menus in cocoa code have common
+ if (ProfileChooserView::IsShowing())
+ ProfileChooserView::Hide();
+ } else {
+ if (AvatarMenuBubbleView::IsShowing())
+ AvatarMenuBubbleView::Hide();
+ }
Roger Tawa OOO till Jul 10th 2015/05/14 18:55:02 You don't need the calls to IsShowing() in both ca
gogerald1 2015/05/14 21:35:22 Done.
+}
+
int BrowserView::GetRenderViewHeightInsetWithDetachedBookmarkBar() {
if (browser_->bookmark_bar_state() != BookmarkBar::DETACHED ||
!bookmark_bar_view_.get() || !bookmark_bar_view_->IsDetached()) {

Powered by Google App Engine
This is Rietveld 408576698