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

Unified Diff: chrome/browser/ui/views/browser_dialogs_views_mac.cc

Issue 2041723002: [Mac] Dismiss an open page info dialog when the location icon is clicked. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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/browser_dialogs_views_mac.cc
diff --git a/chrome/browser/ui/views/browser_dialogs_views_mac.cc b/chrome/browser/ui/views/browser_dialogs_views_mac.cc
index f30448add01b2e69586eb22d5804f244625825ef..0857715c13bdd769aead5d308a26fba9d7c485f1 100644
--- a/chrome/browser/ui/views/browser_dialogs_views_mac.cc
+++ b/chrome/browser/ui/views/browser_dialogs_views_mac.cc
@@ -26,6 +26,12 @@ void ShowWebsiteSettingsBubbleViewsAtPoint(
content::WebContents* web_contents,
const GURL& virtual_url,
const security_state::SecurityStateModel::SecurityInfo& security_info) {
+ // Don't show the popup again if it's already showing. A second click on the
+ // location icon in the omnibox will dismiss an open popup. This is consistent
+ // with the non-Mac views implementation.
tapted 2016/06/06 05:06:37 toolkit-views does something weird around this in
dominickn 2016/06/08 03:03:08 Done.
+ if (WebsiteSettingsPopupView::IsPopupShowing())
+ return;
+
WebsiteSettingsPopupView::ShowPopup(
nullptr, gfx::Rect(anchor_point, gfx::Size()), profile, web_contents,
virtual_url, security_info);

Powered by Google App Engine
This is Rietveld 408576698