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

Unified Diff: ash/common/system/overview/overview_button_tray.cc

Issue 2734933004: ash: Use SessionController instead of SessionStateDelegate (Closed)
Patch Set: rebase to get WorkspaceLayoutManagerSoloTest change 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 | « ash/common/system/date/date_default_view.cc ('k') | ash/common/system/tiles/tiles_default_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/system/overview/overview_button_tray.cc
diff --git a/ash/common/system/overview/overview_button_tray.cc b/ash/common/system/overview/overview_button_tray.cc
index 2b7d243d2e182e975f610dda40cf126905129356..8207e7d66a16ce9ba9a90ea71341ba438ca79f71 100644
--- a/ash/common/system/overview/overview_button_tray.cc
+++ b/ash/common/system/overview/overview_button_tray.cc
@@ -4,7 +4,7 @@
#include "ash/common/system/overview/overview_button_tray.h"
-#include "ash/common/session/session_state_delegate.h"
+#include "ash/common/session/session_controller.h"
#include "ash/common/shelf/shelf_constants.h"
#include "ash/common/system/tray/system_tray_delegate.h"
#include "ash/common/system/tray/tray_constants.h"
@@ -34,12 +34,12 @@ OverviewButtonTray::OverviewButtonTray(WmShelf* wm_shelf)
set_separator_visibility(false);
Shell::GetInstance()->AddShellObserver(this);
- WmShell::Get()->GetSessionStateDelegate()->AddSessionStateObserver(this);
+ WmShell::Get()->session_controller()->AddSessionStateObserver(this);
}
OverviewButtonTray::~OverviewButtonTray() {
Shell::GetInstance()->RemoveShellObserver(this);
- WmShell::Get()->GetSessionStateDelegate()->RemoveSessionStateObserver(this);
+ WmShell::Get()->session_controller()->RemoveSessionStateObserver(this);
}
void OverviewButtonTray::UpdateAfterLoginStatusChange(LoginStatus status) {
@@ -110,14 +110,13 @@ void OverviewButtonTray::UpdateIconVisibility() {
// not change during transient times in which CanSelect is false. Such as when
// a modal dialog is present.
WmShell* shell = WmShell::Get();
- SessionStateDelegate* session_state_delegate =
- shell->GetSessionStateDelegate();
+ SessionController* session_controller = shell->session_controller();
SetVisible(
shell->maximize_mode_controller()->IsMaximizeModeWindowManagerEnabled() &&
- session_state_delegate->IsActiveUserSessionStarted() &&
- !session_state_delegate->IsScreenLocked() &&
- session_state_delegate->GetSessionState() ==
+ session_controller->IsActiveUserSessionStarted() &&
+ !session_controller->IsScreenLocked() &&
+ session_controller->GetSessionState() ==
session_manager::SessionState::ACTIVE &&
shell->system_tray_delegate()->GetUserLoginStatus() !=
LoginStatus::KIOSK_APP &&
« no previous file with comments | « ash/common/system/date/date_default_view.cc ('k') | ash/common/system/tiles/tiles_default_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698