OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/policy/cloud/user_policy_signin_service_factory.h" | 5 #include "chrome/browser/policy/cloud/user_policy_signin_service_factory.h" |
6 | 6 |
7 #include "base/memory/ref_counted.h" | 7 #include "base/memory/ref_counted.h" |
8 #include "base/prefs/pref_service.h" | 8 #include "base/prefs/pref_service.h" |
9 #include "chrome/browser/browser_process.h" | 9 #include "chrome/browser/browser_process.h" |
10 #include "chrome/browser/policy/cloud/user_cloud_policy_manager_factory.h" | 10 #include "chrome/browser/policy/cloud/user_cloud_policy_manager_factory.h" |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 // trigger a token fetch too early (this isn't a problem on other platforms, | 91 // trigger a token fetch too early (this isn't a problem on other platforms, |
92 // because the refresh token isn't available that early). | 92 // because the refresh token isn't available that early). |
93 return false; | 93 return false; |
94 #else | 94 #else |
95 // Create this object when the profile is created so it can track any | 95 // Create this object when the profile is created so it can track any |
96 // user signin activity. | 96 // user signin activity. |
97 return true; | 97 return true; |
98 #endif | 98 #endif |
99 } | 99 } |
100 | 100 |
| 101 bool UserPolicySigninServiceFactory::ServiceIsNULLWhileTesting() const { |
| 102 return true; |
| 103 } |
| 104 |
101 void UserPolicySigninServiceFactory::RegisterProfilePrefs( | 105 void UserPolicySigninServiceFactory::RegisterProfilePrefs( |
102 user_prefs::PrefRegistrySyncable* user_prefs) { | 106 user_prefs::PrefRegistrySyncable* user_prefs) { |
103 #if defined(OS_ANDROID) | 107 #if defined(OS_ANDROID) |
104 user_prefs->RegisterInt64Pref( | 108 user_prefs->RegisterInt64Pref( |
105 prefs::kLastPolicyCheckTime, | 109 prefs::kLastPolicyCheckTime, |
106 0, | 110 0, |
107 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); | 111 user_prefs::PrefRegistrySyncable::UNSYNCABLE_PREF); |
108 #endif | 112 #endif |
109 } | 113 } |
110 | 114 |
111 } // namespace policy | 115 } // namespace policy |
OLD | NEW |