| Index: chromeos/login/login_state.h
|
| diff --git a/chromeos/login/login_state.h b/chromeos/login/login_state.h
|
| index 68966f57ec721b875b2f0c0ad40f385b1924753a..7aae3efc9d8b5531532e5634893b83112a47b146 100644
|
| --- a/chromeos/login/login_state.h
|
| +++ b/chromeos/login/login_state.h
|
| @@ -34,6 +34,7 @@ class CHROMEOS_EXPORT LoginState {
|
| class Observer {
|
| public:
|
| // Called when either the login state or the logged in user type changes.
|
| + // TODO(tengs): Should we notify the observer when the session is started?
|
| virtual void LoggedInStateChanged(LoggedInState state) = 0;
|
|
|
| protected:
|
| @@ -53,6 +54,9 @@ class CHROMEOS_EXPORT LoginState {
|
| // Set the logged in state and user type.
|
| void SetLoggedInState(LoggedInState state, LoggedInUserType type);
|
|
|
| + // Set whether the browser session is started.
|
| + void SetSessionStarted(bool session_started);
|
| +
|
| // Get the logged in state / user type.
|
| LoggedInState GetLoggedInState() const;
|
| LoggedInUserType GetLoggedInUserType() const;
|
| @@ -70,6 +74,11 @@ class CHROMEOS_EXPORT LoginState {
|
| // (i.e., non public nor locally managed account).
|
| bool IsUserGaiaAuthenticated() const;
|
|
|
| + // Returns true if the browser session is started. User login occurs before
|
| + // the session starts. Some procedures can take place during this iterval,
|
| + // so we need to provide this distinction.
|
| + bool IsSessionStarted() const;
|
| +
|
| private:
|
| LoginState();
|
| virtual ~LoginState();
|
| @@ -78,6 +87,7 @@ class CHROMEOS_EXPORT LoginState {
|
|
|
| LoggedInState logged_in_state_;
|
| LoggedInUserType logged_in_user_type_;
|
| + bool session_started_;
|
| ObserverList<Observer> observer_list_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(LoginState);
|
|
|