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

Unified Diff: chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h

Issue 168813002: Refactor user pods to use authType property for distinct authentication modes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix ScreenLockerTest Created 6 years, 10 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: chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h
diff --git a/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h b/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h
index 2741317dade85794f6f73ce9463162c3fad385db..2069100597107b71d0d640e1fca48ce1914e2c08 100644
--- a/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h
+++ b/chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h
@@ -79,6 +79,12 @@ class LoginDisplayWebUIHandler {
virtual void ShowUserPodButton(const std::string& username,
const std::string& iconURL,
const base::Closure& click_callback) = 0;
+ virtual void HideUserPodButton(const std::string& username) = 0;
+ virtual void SetAuthType(const std::string& username,
+ LoginDisplay::AuthType auth_type,
+ const std::string& initial_value) = 0;
+ virtual LoginDisplay::AuthType GetAuthType(const std::string& username)
+ const = 0;
virtual void ShowError(int login_attempts,
const std::string& error_text,
const std::string& help_link_text,
@@ -279,6 +285,12 @@ class SigninScreenHandler
virtual void ShowUserPodButton(const std::string& username,
const std::string& iconURL,
const base::Closure& click_callback) OVERRIDE;
+ virtual void HideUserPodButton(const std::string& username) OVERRIDE;
+ virtual void SetAuthType(const std::string& username,
+ LoginDisplay::AuthType auth_type,
+ const std::string& initial_value) OVERRIDE;
+ virtual LoginDisplay::AuthType GetAuthType(const std::string& username)
+ const OVERRIDE;
virtual void ShowError(int login_attempts,
const std::string& error_text,
const std::string& help_link_text,
@@ -370,6 +382,7 @@ class SigninScreenHandler
static void FillUserDictionary(User* user,
bool is_owner,
bool is_signin_to_add,
+ LoginDisplay::AuthType auth_type,
base::DictionaryValue* user_dict);
// Sends user list to account picker.
@@ -526,6 +539,10 @@ class SigninScreenHandler
// Map of callbacks run when the custom button on a user pod is clicked.
std::map<std::string, base::Closure> user_pod_button_callback_map_;
+ // Map of usernames to their current authentication type. If a user is not
+ // contained in the map, it is using the default authentication type.
+ std::map<std::string, LoginDisplay::AuthType> user_auth_type_map_;
+
// Non-owning ptr.
// TODO (ygorshenin@): remove this dependency.
GaiaScreenHandler* gaia_screen_handler_;

Powered by Google App Engine
This is Rietveld 408576698