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

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

Issue 10909220: Removes caching of whether the launcher should be visible from (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: auto-hide Created 8 years, 3 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/status_area_widget.cc ('k') | ash/system/tray/system_tray_bubble.cc » ('j') | 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 46df3d527474dc81d9c9bf2b6887a827d6d33b70..38ca2705cf17e104dab0677962a0df232e3f036a 100644
--- a/ash/system/tray/system_tray.cc
+++ b/ash/system/tray/system_tray.cc
@@ -31,6 +31,7 @@
#include "ash/system/tray_update.h"
#include "ash/system/user/login_status.h"
#include "ash/system/user/tray_user.h"
+#include "ash/wm/shelf_layout_manager.h"
#include "base/logging.h"
#include "base/timer.h"
#include "base/utf_string_conversions.h"
@@ -268,7 +269,7 @@ void SystemTray::RemoveBubble(SystemTrayBubble* bubble) {
if (bubble == bubble_.get()) {
DestroyBubble();
UpdateNotificationBubble(); // State changed, re-create notifications.
- UpdateShouldShowLauncher();
+ Shell::GetInstance()->shelf()->UpdateAutoHideState();
} else if (bubble == notification_bubble_) {
notification_bubble_.reset();
status_area_widget()->SetHideWebNotifications(false);
@@ -335,11 +336,6 @@ void SystemTray::ShowItems(const std::vector<SystemTrayItem*>& items,
init_params.arrow_color = kBackgroundColor;
}
init_params.arrow_offset = arrow_offset;
- // |bubble_->InitView()| shows and activates the status tray popup, which
- // can trigger the shelf to hide (if auto-hide is turned on). So it is
- // necessary to update the desired launcher visibility before showing the
- // status bubble.
- UpdateShouldShowLauncher();
bubble_->InitView(anchor, init_params, delegate->GetUserLoginStatus());
}
// Save height of default view for creating detailed views directly.
@@ -353,7 +349,7 @@ void SystemTray::ShowItems(const std::vector<SystemTrayItem*>& items,
UpdateNotificationBubble(); // State changed, re-create notifications.
status_area_widget()->SetHideWebNotifications(true);
- UpdateShouldShowLauncher();
+ Shell::GetInstance()->shelf()->UpdateAutoHideState();
}
void SystemTray::UpdateNotificationBubble() {
« no previous file with comments | « ash/system/status_area_widget.cc ('k') | ash/system/tray/system_tray_bubble.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698