| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/memory/singleton.h" | 11 #include "base/memory/singleton.h" |
| 12 #include "base/memory/weak_ptr.h" | 12 #include "base/memory/weak_ptr.h" |
| 13 #include "base/observer_list.h" | 13 #include "base/observer_list.h" |
| 14 #include "chrome/browser/chromeos/base/locale_util.h" | 14 #include "chrome/browser/chromeos/base/locale_util.h" |
| 15 #include "chrome/browser/chromeos/login/auth/authenticator.h" | 15 #include "chrome/browser/chromeos/login/auth/authenticator.h" |
| 16 #include "chrome/browser/chromeos/login/signin/oauth2_login_manager.h" | 16 #include "chrome/browser/chromeos/login/signin/oauth2_login_manager.h" |
| 17 #include "chrome/browser/chromeos/login/users/user.h" | |
| 18 #include "chromeos/dbus/session_manager_client.h" | 17 #include "chromeos/dbus/session_manager_client.h" |
| 19 #include "chromeos/login/auth/user_context.h" | 18 #include "chromeos/login/auth/user_context.h" |
| 19 #include "components/user_manager/user.h" |
| 20 #include "net/base/network_change_notifier.h" | 20 #include "net/base/network_change_notifier.h" |
| 21 | 21 |
| 22 class PrefRegistrySimple; | 22 class PrefRegistrySimple; |
| 23 class PrefService; | 23 class PrefService; |
| 24 class Profile; | 24 class Profile; |
| 25 | 25 |
| 26 namespace chromeos { | 26 namespace chromeos { |
| 27 | 27 |
| 28 class UserSessionManagerDelegate { | 28 class UserSessionManagerDelegate { |
| 29 public: | 29 public: |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 std::string* chrome_client_secret); | 121 std::string* chrome_client_secret); |
| 122 void SetAppModeChromeClientOAuthInfo( | 122 void SetAppModeChromeClientOAuthInfo( |
| 123 const std::string& chrome_client_id, | 123 const std::string& chrome_client_id, |
| 124 const std::string& chrome_client_secret); | 124 const std::string& chrome_client_secret); |
| 125 | 125 |
| 126 // Changes browser locale (selects best suitable locale from different | 126 // Changes browser locale (selects best suitable locale from different |
| 127 // user settings). Returns true if callback will be called. | 127 // user settings). Returns true if callback will be called. |
| 128 // Returns true if callback will be called. | 128 // Returns true if callback will be called. |
| 129 bool RespectLocalePreference( | 129 bool RespectLocalePreference( |
| 130 Profile* profile, | 130 Profile* profile, |
| 131 const User* user, | 131 const user_manager::User* user, |
| 132 scoped_ptr<locale_util::SwitchLanguageCallback> callback) const; | 132 scoped_ptr<locale_util::SwitchLanguageCallback> callback) const; |
| 133 | 133 |
| 134 void AddSessionStateObserver(UserSessionStateObserver* observer); | 134 void AddSessionStateObserver(UserSessionStateObserver* observer); |
| 135 void RemoveSessionStateObserver(UserSessionStateObserver* observer); | 135 void RemoveSessionStateObserver(UserSessionStateObserver* observer); |
| 136 | 136 |
| 137 private: | 137 private: |
| 138 friend struct DefaultSingletonTraits<UserSessionManager>; | 138 friend struct DefaultSingletonTraits<UserSessionManager>; |
| 139 | 139 |
| 140 typedef std::set<std::string> SigninSessionRestoreStateSet; | 140 typedef std::set<std::string> SigninSessionRestoreStateSet; |
| 141 | 141 |
| (...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 257 // Chrome oauth client id and secret - override values for kiosk mode. | 257 // Chrome oauth client id and secret - override values for kiosk mode. |
| 258 std::string chrome_client_id_; | 258 std::string chrome_client_id_; |
| 259 std::string chrome_client_secret_; | 259 std::string chrome_client_secret_; |
| 260 | 260 |
| 261 DISALLOW_COPY_AND_ASSIGN(UserSessionManager); | 261 DISALLOW_COPY_AND_ASSIGN(UserSessionManager); |
| 262 }; | 262 }; |
| 263 | 263 |
| 264 } // namespace chromeos | 264 } // namespace chromeos |
| 265 | 265 |
| 266 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ | 266 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ |
| OLD | NEW |