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

Unified Diff: chrome/browser/ui/ash/session_state_delegate_chromeos.cc

Issue 560033002: Fixed suggesting adding more users into multi-profile session when we don't have more (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update after review Created 6 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: chrome/browser/ui/ash/session_state_delegate_chromeos.cc
diff --git a/chrome/browser/ui/ash/session_state_delegate_chromeos.cc b/chrome/browser/ui/ash/session_state_delegate_chromeos.cc
index bcf70f4fe6d38cc90649745ae0626654b408e45c..fadfdb21d7e867beec0e55bad1fc35bfc197081c 100644
--- a/chrome/browser/ui/ash/session_state_delegate_chromeos.cc
+++ b/chrome/browser/ui/ash/session_state_delegate_chromeos.cc
@@ -83,6 +83,18 @@ int SessionStateDelegateChromeos::NumberOfLoggedInUsers() const {
return user_manager::UserManager::Get()->GetLoggedInUsers().size();
}
+bool SessionStateDelegateChromeos::CanAddUserToMultiProfile(
+ MultiProfileAddUserError* error) const {
+ if (user_manager::UserManager::Get()
+ ->GetUsersAdmittedForMultiProfile()
James Cook 2014/09/23 16:02:12 I know this was not added in this CL, but the name
Roman Sorokin (ftl) 2014/09/24 08:30:47 Ok, I'll do it in another CL. On 2014/09/23 16:02:
+ .size() == 0) {
+ if (error)
+ *error = MULTIPROFILE_ADD_USER_ERROR_OUT_OF_USERS;
+ return false;
+ }
+ return SessionStateDelegate::CanAddUserToMultiProfile(error);
+}
+
bool SessionStateDelegateChromeos::IsActiveUserSessionStarted() const {
return user_manager::UserManager::Get()->IsSessionStarted();
}

Powered by Google App Engine
This is Rietveld 408576698