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

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

Issue 2876363004: Fix activation issues with SystemTrayBubble. (Closed)
Patch Set: Created 3 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
« no previous file with comments | « ash/system/network/network_state_list_detailed_view.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/system/tray/system_tray.cc
diff --git a/ash/system/tray/system_tray.cc b/ash/system/tray/system_tray.cc
index e3d178fff51443e31adf0fb66aad88163c6b5c5b..7d405e31ed7726f2c87cb731823187565d7de431 100644
--- a/ash/system/tray/system_tray.cc
+++ b/ash/system/tray/system_tray.cc
@@ -478,6 +478,10 @@ void SystemTray::ShowItems(const std::vector<SystemTrayItem*>& items,
GetAnchorAlignment(), kTrayMenuMinimumWidth, kTrayPopupMaxWidth);
// TODO(oshima): Change TrayBubbleView itself.
init_params.can_activate = false;
+ // The bubble is not initially activatable, but will become activatable if
+ // the user presses Tab. For behavioral consistency with the non-activatable
+ // scenario, don't close on deactivation after Tab either.
+ init_params.close_on_deactivate = false;
if (detailed) {
// This is the case where a volume control or brightness control bubble
// is created.
@@ -486,8 +490,6 @@ void SystemTray::ShowItems(const std::vector<SystemTrayItem*>& items,
} else {
init_params.bg_color = kHeaderBackgroundColor;
}
- if (bubble_type == SystemTrayBubble::BUBBLE_TYPE_DEFAULT)
- init_params.close_on_deactivate = !persistent;
SystemTrayBubble* bubble = new SystemTrayBubble(this, items, bubble_type);
system_bubble_.reset(new SystemBubbleWrapper(bubble));
« no previous file with comments | « ash/system/network/network_state_list_detailed_view.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698