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

Side by Side Diff: chrome/browser/policy/cloud/user_cloud_policy_manager_factory.h

Issue 14141006: [components] Switch {RefCounted}ProfileKeyedService to use BrowserContext (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: for review Created 7 years, 8 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 (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 #ifndef CHROME_BROWSER_POLICY_CLOUD_USER_CLOUD_POLICY_MANAGER_FACTORY_H_ 5 #ifndef CHROME_BROWSER_POLICY_CLOUD_USER_CLOUD_POLICY_MANAGER_FACTORY_H_
6 #define CHROME_BROWSER_POLICY_CLOUD_USER_CLOUD_POLICY_MANAGER_FACTORY_H_ 6 #define CHROME_BROWSER_POLICY_CLOUD_USER_CLOUD_POLICY_MANAGER_FACTORY_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 UserCloudPolicyManagerFactory(); 56 UserCloudPolicyManagerFactory();
57 virtual ~UserCloudPolicyManagerFactory(); 57 virtual ~UserCloudPolicyManagerFactory();
58 58
59 // See comments for the static versions above. 59 // See comments for the static versions above.
60 UserCloudPolicyManager* GetManagerForProfile(Profile* profile); 60 UserCloudPolicyManager* GetManagerForProfile(Profile* profile);
61 scoped_ptr<UserCloudPolicyManager> CreateManagerForProfile( 61 scoped_ptr<UserCloudPolicyManager> CreateManagerForProfile(
62 Profile* profile, 62 Profile* profile,
63 bool force_immediate_load); 63 bool force_immediate_load);
64 64
65 // ProfileKeyedBaseFactory: 65 // ProfileKeyedBaseFactory:
66 virtual void ProfileShutdown(Profile* profile) OVERRIDE; 66 virtual void ProfileShutdown(content::BrowserContext* profile) OVERRIDE;
67 virtual void SetEmptyTestingFactory(Profile* profile) OVERRIDE; 67 virtual void SetEmptyTestingFactory(
68 virtual void CreateServiceNow(Profile* profile) OVERRIDE; 68 content::BrowserContext* profile) OVERRIDE;
69 virtual void CreateServiceNow(content::BrowserContext* profile) OVERRIDE;
69 70
70 // Invoked by UserCloudPolicyManager to register/unregister instances. 71 // Invoked by UserCloudPolicyManager to register/unregister instances.
71 void Register(Profile* profile, UserCloudPolicyManager* instance); 72 void Register(Profile* profile, UserCloudPolicyManager* instance);
72 void Unregister(Profile* profile, UserCloudPolicyManager* instance); 73 void Unregister(Profile* profile, UserCloudPolicyManager* instance);
73 74
74 typedef std::map<Profile*, UserCloudPolicyManager*> ManagerMap; 75 typedef std::map<Profile*, UserCloudPolicyManager*> ManagerMap;
75 ManagerMap managers_; 76 ManagerMap managers_;
76 77
77 DISALLOW_COPY_AND_ASSIGN(UserCloudPolicyManagerFactory); 78 DISALLOW_COPY_AND_ASSIGN(UserCloudPolicyManagerFactory);
78 }; 79 };
79 80
80 } // namespace policy 81 } // namespace policy
81 82
82 #endif // CHROME_BROWSER_POLICY_CLOUD_USER_CLOUD_POLICY_MANAGER_FACTORY_H_ 83 #endif // CHROME_BROWSER_POLICY_CLOUD_USER_CLOUD_POLICY_MANAGER_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698