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

Unified Diff: ash/common/system/tray/system_tray.cc

Issue 2784163003: Dismiss the system menu if the status area is clicked while the menu is open. (Closed)
Patch Set: Adress the coments on PS#1 Created 3 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/tray/system_tray.cc
diff --git a/ash/common/system/tray/system_tray.cc b/ash/common/system/tray/system_tray.cc
index b471a79cd70638c73d35de43c0c5c0d0eba675d1..79d76338186a00944900a96e6df48c9155cfeb2b 100644
--- a/ash/common/system/tray/system_tray.cc
+++ b/ash/common/system/tray/system_tray.cc
@@ -707,9 +707,9 @@ void SystemTray::ActivateBubble() {
}
bool SystemTray::PerformAction(const ui::Event& event) {
- // If we're already showing the default view, hide it; otherwise, show it
- // (and hide any popup that's currently shown).
- if (HasSystemBubbleType(SystemTrayBubble::BUBBLE_TYPE_DEFAULT)) {
+ // If we're already showing the menu, hide it; otherwise, show it (and hide
+ // any popup that's currently shown).
+ if (HasSystemBubble()) {
system_bubble_->bubble()->Close();
} else {
ShowDefaultView(BUBBLE_CREATE_NEW);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698