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

Unified Diff: ash/test/test_system_tray_delegate.cc

Issue 2041233005: Moves ash::user::LoginStatus to ash/common (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tweaks 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: ash/test/test_system_tray_delegate.cc
diff --git a/ash/test/test_system_tray_delegate.cc b/ash/test/test_system_tray_delegate.cc
index 7745bc954b035368b292eccf96a08859732219fe..d24936e5c5fdef00191009bb965b309465b16f52 100644
--- a/ash/test/test_system_tray_delegate.cc
+++ b/ash/test/test_system_tray_delegate.cc
@@ -17,7 +17,7 @@ namespace test {
namespace {
-user::LoginStatus g_initial_status = user::LOGGED_IN_USER;
+LoginStatus g_initial_status = LoginStatus::USER;
} // namespace
@@ -31,12 +31,11 @@ TestSystemTrayDelegate::~TestSystemTrayDelegate() {
}
// static
-void TestSystemTrayDelegate::SetInitialLoginStatus(
- user::LoginStatus login_status) {
+void TestSystemTrayDelegate::SetInitialLoginStatus(LoginStatus login_status) {
g_initial_status = login_status;
}
-void TestSystemTrayDelegate::SetLoginStatus(user::LoginStatus login_status) {
+void TestSystemTrayDelegate::SetLoginStatus(LoginStatus login_status) {
login_status_ = login_status;
Shell::GetInstance()->UpdateAfterLoginStatusChange(login_status);
}
@@ -51,9 +50,9 @@ void TestSystemTrayDelegate::ClearSessionLengthLimit() {
session_length_limit_set_ = false;
}
-user::LoginStatus TestSystemTrayDelegate::GetUserLoginStatus() const {
+LoginStatus TestSystemTrayDelegate::GetUserLoginStatus() const {
// Initial login status has been changed for testing.
- if (g_initial_status != user::LOGGED_IN_USER &&
+ if (g_initial_status != LoginStatus::USER &&
g_initial_status == login_status_) {
return login_status_;
}
@@ -64,14 +63,14 @@ user::LoginStatus TestSystemTrayDelegate::GetUserLoginStatus() const {
Shell::GetInstance()->session_state_delegate();
if (!delegate->IsActiveUserSessionStarted())
- return ash::user::LOGGED_IN_NONE;
+ return LoginStatus::NOT_LOGGED_IN;
if (delegate->IsScreenLocked())
- return user::LOGGED_IN_LOCKED;
+ return LoginStatus::LOCKED;
return login_status_;
}
bool TestSystemTrayDelegate::IsUserSupervised() const {
- return login_status_ == ash::user::LOGGED_IN_SUPERVISED;
+ return login_status_ == LoginStatus::SUPERVISED;
}
bool TestSystemTrayDelegate::ShouldShowDisplayNotification() {

Powered by Google App Engine
This is Rietveld 408576698