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

Side by Side Diff: chrome/browser/chromeos/login/app_launch_signin_screen.cc

Issue 2418833003: Remove use of deprecated base::ListValue::Append(Value*) overload in //chrome/browser/chromeos (Closed)
Patch Set: use-after-move Created 4 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "chrome/browser/chromeos/login/app_launch_signin_screen.h" 5 #include "chrome/browser/chromeos/login/app_launch_signin_screen.h"
6 6
7 #include <utility>
8
9 #include "base/memory/ptr_util.h"
7 #include "base/values.h" 10 #include "base/values.h"
8 #include "chrome/browser/chromeos/login/help_app_launcher.h" 11 #include "chrome/browser/chromeos/login/help_app_launcher.h"
9 #include "chrome/browser/chromeos/login/screens/user_selection_screen.h" 12 #include "chrome/browser/chromeos/login/screens/user_selection_screen.h"
10 #include "chrome/browser/chromeos/login/session/user_session_manager.h" 13 #include "chrome/browser/chromeos/login/session/user_session_manager.h"
11 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h" 14 #include "chrome/browser/ui/webui/chromeos/login/signin_screen_handler.h"
12 #include "chrome/grit/generated_resources.h" 15 #include "chrome/grit/generated_resources.h"
13 #include "chromeos/login/auth/user_context.h" 16 #include "chromeos/login/auth/user_context.h"
14 #include "components/proximity_auth/screenlock_bridge.h" 17 #include "components/proximity_auth/screenlock_bridge.h"
15 #include "components/user_manager/user_manager.h" 18 #include "components/user_manager/user_manager.h"
16 #include "content/public/browser/browser_thread.h" 19 #include "content/public/browser/browser_thread.h"
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 base::ListValue users_list; 207 base::ListValue users_list;
205 const user_manager::UserList& users = GetUsers(); 208 const user_manager::UserList& users = GetUsers();
206 209
207 for (user_manager::UserList::const_iterator it = users.begin(); 210 for (user_manager::UserList::const_iterator it = users.begin();
208 it != users.end(); 211 it != users.end();
209 ++it) { 212 ++it) {
210 proximity_auth::ScreenlockBridge::LockHandler::AuthType initial_auth_type = 213 proximity_auth::ScreenlockBridge::LockHandler::AuthType initial_auth_type =
211 UserSelectionScreen::ShouldForceOnlineSignIn(*it) 214 UserSelectionScreen::ShouldForceOnlineSignIn(*it)
212 ? proximity_auth::ScreenlockBridge::LockHandler::ONLINE_SIGN_IN 215 ? proximity_auth::ScreenlockBridge::LockHandler::ONLINE_SIGN_IN
213 : proximity_auth::ScreenlockBridge::LockHandler::OFFLINE_PASSWORD; 216 : proximity_auth::ScreenlockBridge::LockHandler::OFFLINE_PASSWORD;
214 base::DictionaryValue* user_dict = new base::DictionaryValue(); 217 auto user_dict = base::MakeUnique<base::DictionaryValue>();
215 UserSelectionScreen::FillUserDictionary( 218 UserSelectionScreen::FillUserDictionary(
216 *it, 219 *it, true, /* is_owner */
217 true, /* is_owner */ 220 false, /* is_signin_to_add */
218 false, /* is_signin_to_add */ 221 initial_auth_type, NULL, /* public_session_recommended_locales */
219 initial_auth_type, 222 user_dict.get());
220 NULL, /* public_session_recommended_locales */ 223 users_list.Append(std::move(user_dict));
221 user_dict);
222 users_list.Append(user_dict);
223 } 224 }
224 225
225 webui_handler_->LoadUsers(users_list, false); 226 webui_handler_->LoadUsers(users_list, false);
226 } 227 }
227 228
228 void AppLaunchSigninScreen::CheckUserStatus(const AccountId& account_id) {} 229 void AppLaunchSigninScreen::CheckUserStatus(const AccountId& account_id) {}
229 230
230 bool AppLaunchSigninScreen::IsUserWhitelisted(const AccountId& account_id) { 231 bool AppLaunchSigninScreen::IsUserWhitelisted(const AccountId& account_id) {
231 NOTREACHED(); 232 NOTREACHED();
232 return true; 233 return true;
233 } 234 }
234 235
235 } // namespace chromeos 236 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698