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

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

Issue 14507003: Add tray warning for Locally managed users. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix win-aura compile error Created 7 years, 7 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/user_manager_impl.h" 5 #include "chrome/browser/chromeos/login/user_manager_impl.h"
6 6
7 #include <cstddef> 7 #include <cstddef>
8 #include <set> 8 #include <set>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 } 372 }
373 } while (user_exists); 373 } while (user_exists);
374 374
375 g_browser_process->local_state()-> 375 g_browser_process->local_state()->
376 SetInteger(kLocallyManagedUsersNextId, counter); 376 SetInteger(kLocallyManagedUsersNextId, counter);
377 377
378 g_browser_process->local_state()->CommitPendingWrite(); 378 g_browser_process->local_state()->CommitPendingWrite();
379 return id; 379 return id;
380 } 380 }
381 381
382 std::string UserManagerImpl::GetManagerForManagedUser(
383 const std::string& managed_user_id) const {
384 // TODO (antrim): implement this method when we have appropriate API.
385 return std::string();
386 }
387
382 const User* UserManagerImpl::CreateLocallyManagedUserRecord( 388 const User* UserManagerImpl::CreateLocallyManagedUserRecord(
383 const std::string& e_mail, 389 const std::string& e_mail,
384 const string16& display_name) { 390 const string16& display_name) {
385 const User* user = FindLocallyManagedUser(display_name); 391 const User* user = FindLocallyManagedUser(display_name);
386 DCHECK(!user); 392 DCHECK(!user);
387 if (user) 393 if (user)
388 return user; 394 return user;
389 395
390 User* new_user = User::CreateLocallyManagedUser(e_mail); 396 User* new_user = User::CreateLocallyManagedUser(e_mail);
391 ListPrefUpdate prefs_users_update(g_browser_process->local_state(), 397 ListPrefUpdate prefs_users_update(g_browser_process->local_state(),
(...skipping 1053 matching lines...) Expand 10 before | Expand all | Expand 10 after
1445 login_user_type = LoginState::LOGGED_IN_USER_LOCALLY_MANAGED; 1451 login_user_type = LoginState::LOGGED_IN_USER_LOCALLY_MANAGED;
1446 else if (active_user_->GetType() == User::USER_TYPE_KIOSK_APP) 1452 else if (active_user_->GetType() == User::USER_TYPE_KIOSK_APP)
1447 login_user_type = LoginState::LOGGED_IN_USER_KIOSK_APP; 1453 login_user_type = LoginState::LOGGED_IN_USER_KIOSK_APP;
1448 else 1454 else
1449 login_user_type = LoginState::LOGGED_IN_USER_REGULAR; 1455 login_user_type = LoginState::LOGGED_IN_USER_REGULAR;
1450 1456
1451 LoginState::Get()->SetLoggedInState(logged_in_state, login_user_type); 1457 LoginState::Get()->SetLoggedInState(logged_in_state, login_user_type);
1452 } 1458 }
1453 1459
1454 } // namespace chromeos 1460 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/user_manager_impl.h ('k') | chrome/browser/chromeos/system/ash_system_tray_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698