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

Side by Side Diff: chrome/browser/signin/chrome_signin_client.cc

Issue 393343002: Rename "managed (mode|user)" to "supervised user" (part 7) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more alphabetize (and rebase again) Created 6 years, 5 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 | Annotate | Revision Log
OLDNEW
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 #include "chrome/browser/signin/chrome_signin_client.h" 5 #include "chrome/browser/signin/chrome_signin_client.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/guid.h" 8 #include "base/guid.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "chrome/browser/chrome_notification_types.h" 10 #include "chrome/browser/chrome_notification_types.h"
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 106
107 scoped_refptr<TokenWebData> ChromeSigninClient::GetDatabase() { 107 scoped_refptr<TokenWebData> ChromeSigninClient::GetDatabase() {
108 return WebDataServiceFactory::GetTokenWebDataForProfile( 108 return WebDataServiceFactory::GetTokenWebDataForProfile(
109 profile_, Profile::EXPLICIT_ACCESS); 109 profile_, Profile::EXPLICIT_ACCESS);
110 } 110 }
111 111
112 bool ChromeSigninClient::CanRevokeCredentials() { 112 bool ChromeSigninClient::CanRevokeCredentials() {
113 #if defined(OS_CHROMEOS) 113 #if defined(OS_CHROMEOS)
114 // UserManager may not exist in unit_tests. 114 // UserManager may not exist in unit_tests.
115 if (chromeos::UserManager::IsInitialized() && 115 if (chromeos::UserManager::IsInitialized() &&
116 chromeos::UserManager::Get()->IsLoggedInAsLocallyManagedUser()) { 116 chromeos::UserManager::Get()->IsLoggedInAsSupervisedUser()) {
117 // Don't allow revoking credentials for Chrome OS supervised users. 117 // Don't allow revoking credentials for Chrome OS supervised users.
118 // See http://crbug.com/332032 118 // See http://crbug.com/332032
119 LOG(ERROR) << "Attempt to revoke supervised user refresh " 119 LOG(ERROR) << "Attempt to revoke supervised user refresh "
120 << "token detected, ignoring."; 120 << "token detected, ignoring.";
121 return false; 121 return false;
122 } 122 }
123 #else 123 #else
124 // Don't allow revoking credentials for supervised users. 124 // Don't allow revoking credentials for supervised users.
125 // See http://crbug.com/332032 125 // See http://crbug.com/332032
126 if (profile_->IsSupervised()) { 126 if (profile_->IsSupervised()) {
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 218
219 void ChromeSigninClient::UnregisterForCookieChangedNotification() { 219 void ChromeSigninClient::UnregisterForCookieChangedNotification() {
220 // Note that it's allowed to call this method multiple times without an 220 // Note that it's allowed to call this method multiple times without an
221 // intervening call to |RegisterForCookieChangedNotification()|. 221 // intervening call to |RegisterForCookieChangedNotification()|.
222 content::Source<Profile> source(profile_); 222 content::Source<Profile> source(profile_);
223 if (!registrar_.IsRegistered( 223 if (!registrar_.IsRegistered(
224 this, chrome::NOTIFICATION_COOKIE_CHANGED, source)) 224 this, chrome::NOTIFICATION_COOKIE_CHANGED, source))
225 return; 225 return;
226 registrar_.Remove(this, chrome::NOTIFICATION_COOKIE_CHANGED, source); 226 registrar_.Remove(this, chrome::NOTIFICATION_COOKIE_CHANGED, source);
227 } 227 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_impl.h ('k') | chrome/browser/supervised_user/chromeos/manager_password_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698