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

Side by Side Diff: chrome/browser/supervised_user/child_accounts/child_account_service_android.cc

Issue 1128173005: Clean up ProfileManager interface. Base URL: https://chromium.googlesource.com/chromium/src@issue479309
Patch Set: sync Created 5 years, 6 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 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/supervised_user/child_accounts/child_account_service_an droid.h" 5 #include "chrome/browser/supervised_user/child_accounts/child_account_service_an droid.h"
6 6
7 #include "chrome/browser/browser_process.h"
7 #include "chrome/browser/profiles/profile_manager.h" 8 #include "chrome/browser/profiles/profile_manager.h"
8 #include "chrome/browser/supervised_user/child_accounts/child_account_service.h" 9 #include "chrome/browser/supervised_user/child_accounts/child_account_service.h"
9 #include "chrome/browser/supervised_user/child_accounts/child_account_service_fa ctory.h" 10 #include "chrome/browser/supervised_user/child_accounts/child_account_service_fa ctory.h"
10 #include "jni/ChildAccountService_jni.h" 11 #include "jni/ChildAccountService_jni.h"
11 12
12 jboolean IsChildAccountDetectionEnabled(JNIEnv* env, jobject obj) { 13 jboolean IsChildAccountDetectionEnabled(JNIEnv* env, jobject obj) {
13 return ChildAccountService::IsChildAccountDetectionEnabled(); 14 return ChildAccountService::IsChildAccountDetectionEnabled();
14 } 15 }
15 16
16 void OnChildAccountSigninComplete(JNIEnv* env, jobject obj) { 17 void OnChildAccountSigninComplete(JNIEnv* env, jobject obj) {
17 VLOG(1) << "OnChildAccountSigninComplete"; 18 VLOG(1) << "OnChildAccountSigninComplete";
18 19
19 Profile* profile = ProfileManager::GetLastUsedProfile(); 20 Profile* profile = g_browser_process->profile_manager()->GetLastUsedProfile();
20 ChildAccountServiceFactory::GetForProfile(profile)->SetIsChildAccount(true); 21 ChildAccountServiceFactory::GetForProfile(profile)->SetIsChildAccount(true);
21 } 22 }
22 23
23 bool RegisterChildAccountService(JNIEnv* env) { 24 bool RegisterChildAccountService(JNIEnv* env) {
24 return RegisterNativesImpl(env); 25 return RegisterNativesImpl(env);
25 } 26 }
OLDNEW
« no previous file with comments | « chrome/browser/status_icons/desktop_notification_balloon.cc ('k') | chrome/browser/task_manager/task_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698