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

Unified Diff: chromeos/login/login_state.cc

Issue 24072006: Return correct window when user is logged in but before session is started. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix unit test compile error Created 7 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
Index: chromeos/login/login_state.cc
diff --git a/chromeos/login/login_state.cc b/chromeos/login/login_state.cc
index 8c8c3291d97d21baadf6daa591a5acd60984c13b..70a9efa59c413e1c03e5a3f0768b2af2c33e8626 100644
--- a/chromeos/login/login_state.cc
+++ b/chromeos/login/login_state.cc
@@ -67,6 +67,11 @@ void LoginState::SetLoggedInState(LoggedInState state,
NotifyObservers();
}
+void LoginState::SetSessionStarted(bool session_started) {
+ DCHECK(GetLoggedInState() == LOGGED_IN_ACTIVE);
+ session_started_ = session_started;
+}
+
LoginState::LoggedInState LoginState::GetLoggedInState() const {
if (AlwaysLoggedIn())
return LOGGED_IN_ACTIVE;
@@ -113,10 +118,15 @@ bool LoginState::IsUserGaiaAuthenticated() const {
type == chromeos::LoginState::LOGGED_IN_USER_OWNER;
}
+bool LoginState::IsSessionStarted() const {
+ return session_started_;
+}
+
// Private methods
LoginState::LoginState() : logged_in_state_(LOGGED_IN_OOBE),
- logged_in_user_type_(LOGGED_IN_USER_NONE) {
+ logged_in_user_type_(LOGGED_IN_USER_NONE),
+ session_started_(false) {
}
LoginState::~LoginState() {

Powered by Google App Engine
This is Rietveld 408576698