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

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

Issue 11886079: Revert 177136 due to memory error on Mac ASAN (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 11 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
« no previous file with comments | « chrome/browser/signin/signin_manager.cc ('k') | chrome/browser/signin/signin_manager_fake.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/signin/signin_manager_factory.h" 5 #include "chrome/browser/signin/signin_manager_factory.h"
6 6
7 #include "chrome/browser/prefs/pref_service.h" 7 #include "chrome/browser/prefs/pref_service.h"
8 #include "chrome/browser/profiles/profile_dependency_manager.h" 8 #include "chrome/browser/profiles/profile_dependency_manager.h"
9 #include "chrome/browser/signin/signin_manager.h" 9 #include "chrome/browser/signin/signin_manager.h"
10 #include "chrome/browser/signin/token_service_factory.h" 10 #include "chrome/browser/signin/token_service_factory.h"
11 #include "chrome/browser/ui/global_error/global_error_service_factory.h"
12 #include "chrome/common/pref_names.h" 11 #include "chrome/common/pref_names.h"
13 12
14 SigninManagerFactory::SigninManagerFactory() 13 SigninManagerFactory::SigninManagerFactory()
15 : ProfileKeyedServiceFactory("SigninManager", 14 : ProfileKeyedServiceFactory("SigninManager",
16 ProfileDependencyManager::GetInstance()) { 15 ProfileDependencyManager::GetInstance()) {
17 DependsOn(TokenServiceFactory::GetInstance()); 16 DependsOn(TokenServiceFactory::GetInstance());
18 DependsOn(GlobalErrorServiceFactory::GetInstance());
19 } 17 }
20 18
21 SigninManagerFactory::~SigninManagerFactory() {} 19 SigninManagerFactory::~SigninManagerFactory() {}
22 20
23 // static 21 // static
24 SigninManager* SigninManagerFactory::GetForProfile(Profile* profile) { 22 SigninManager* SigninManagerFactory::GetForProfile(Profile* profile) {
25 return static_cast<SigninManager*>( 23 return static_cast<SigninManager*>(
26 GetInstance()->GetServiceForProfile(profile, true)); 24 GetInstance()->GetServiceForProfile(profile, true));
27 } 25 }
28 26
(...skipping 28 matching lines...) Expand all
57 void SigninManagerFactory::RegisterPrefs(PrefServiceSimple* local_state) { 55 void SigninManagerFactory::RegisterPrefs(PrefServiceSimple* local_state) {
58 local_state->RegisterStringPref(prefs::kGoogleServicesUsernamePattern, ""); 56 local_state->RegisterStringPref(prefs::kGoogleServicesUsernamePattern, "");
59 } 57 }
60 58
61 ProfileKeyedService* SigninManagerFactory::BuildServiceInstanceFor( 59 ProfileKeyedService* SigninManagerFactory::BuildServiceInstanceFor(
62 Profile* profile) const { 60 Profile* profile) const {
63 SigninManager* service = new SigninManager(); 61 SigninManager* service = new SigninManager();
64 service->Initialize(profile); 62 service->Initialize(profile);
65 return service; 63 return service;
66 } 64 }
OLDNEW
« no previous file with comments | « chrome/browser/signin/signin_manager.cc ('k') | chrome/browser/signin/signin_manager_fake.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698