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 // The signin manager encapsulates some functionality tracking | 5 // The signin manager encapsulates some functionality tracking |
6 // which user is signed in. When a user is signed in, a ClientLogin | 6 // which user is signed in. When a user is signed in, a ClientLogin |
7 // request is run on their behalf. Auth tokens are fetched from Google | 7 // request is run on their behalf. Auth tokens are fetched from Google |
8 // and the results are stored in the TokenService. | 8 // and the results are stored in the TokenService. |
9 // | 9 // |
10 // **NOTE** on semantics of SigninManager: | 10 // **NOTE** on semantics of SigninManager: |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
250 // Callback invoked when a policy fetch request has completed. |success| is | 250 // Callback invoked when a policy fetch request has completed. |success| is |
251 // true if policy was successfully fetched. | 251 // true if policy was successfully fetched. |
252 void OnPolicyFetchComplete(bool success); | 252 void OnPolicyFetchComplete(bool success); |
253 | 253 |
254 // Called to create a new profile, which is then signed in with the | 254 // Called to create a new profile, which is then signed in with the |
255 // in-progress auth credentials currently stored in this object. | 255 // in-progress auth credentials currently stored in this object. |
256 void TransferCredentialsToNewProfile(); | 256 void TransferCredentialsToNewProfile(); |
257 | 257 |
258 // Helper function that loads policy with the passed CloudPolicyClient, then | 258 // Helper function that loads policy with the passed CloudPolicyClient, then |
259 // completes the signin process. | 259 // completes the signin process. |
260 void LoadPolicyWithCachedClient(scoped_ptr<policy::CloudPolicyClient> client); | 260 void LoadPolicyWithCachedClient(); |
261 | 261 |
262 // Callback invoked once a profile is created, so we can complete the | 262 // Callback invoked once a profile is created, so we can complete the |
263 // credentials transfer and load policy. | 263 // credentials transfer and load policy. |
264 void CompleteSigninForNewProfile(Profile* profile, | 264 void CompleteSigninForNewProfile(Profile* profile, |
265 Profile::CreateStatus status); | 265 Profile::CreateStatus status); |
266 #endif // defined(ENABLE_CONFIGURATION_POLICY) && !defined(OS_CHROMEOS) | 266 #endif // defined(ENABLE_CONFIGURATION_POLICY) && !defined(OS_CHROMEOS) |
267 | 267 |
268 // Invoked once policy has been loaded to complete user signin. | 268 // Invoked once policy has been loaded to complete user signin. |
269 void CompleteSigninAfterPolicyLoad(); | 269 void CompleteSigninAfterPolicyLoad(); |
270 | 270 |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
325 #if defined(ENABLE_CONFIGURATION_POLICY) && !defined(OS_CHROMEOS) | 325 #if defined(ENABLE_CONFIGURATION_POLICY) && !defined(OS_CHROMEOS) |
326 // CloudPolicyClient reference we keep while determining whether to create | 326 // CloudPolicyClient reference we keep while determining whether to create |
327 // a new profile for an enterprise user or not. | 327 // a new profile for an enterprise user or not. |
328 scoped_ptr<policy::CloudPolicyClient> policy_client_; | 328 scoped_ptr<policy::CloudPolicyClient> policy_client_; |
329 #endif | 329 #endif |
330 | 330 |
331 DISALLOW_COPY_AND_ASSIGN(SigninManager); | 331 DISALLOW_COPY_AND_ASSIGN(SigninManager); |
332 }; | 332 }; |
333 | 333 |
334 #endif // CHROME_BROWSER_SIGNIN_SIGNIN_MANAGER_H_ | 334 #endif // CHROME_BROWSER_SIGNIN_SIGNIN_MANAGER_H_ |
OLD | NEW |