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

Side by Side Diff: chrome/browser/policy/profile_policy_connector.h

Issue 15517005: Remove references to Profile from browser_context_keyed_service. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase & style Created 7 years, 7 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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_PROFILE_POLICY_CONNECTOR_H_ 5 #ifndef CHROME_BROWSER_POLICY_PROFILE_POLICY_CONNECTOR_H_
6 #define CHROME_BROWSER_POLICY_PROFILE_POLICY_CONNECTOR_H_ 6 #define CHROME_BROWSER_POLICY_PROFILE_POLICY_CONNECTOR_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 10 matching lines...) Expand all
21 namespace base { 21 namespace base {
22 class SequencedTaskRunner; 22 class SequencedTaskRunner;
23 } 23 }
24 24
25 namespace policy { 25 namespace policy {
26 26
27 class DeviceLocalAccountPolicyProvider; 27 class DeviceLocalAccountPolicyProvider;
28 class ManagedModePolicyProvider; 28 class ManagedModePolicyProvider;
29 class PolicyService; 29 class PolicyService;
30 30
31 // A ProfileKeyedService that creates and manages the per-Profile policy 31 // A BrowserContextKeyedService that creates and manages the per-Profile policy
32 // components. 32 // components.
33 class ProfilePolicyConnector : public ProfileKeyedService { 33 class ProfilePolicyConnector : public BrowserContextKeyedService {
34 public: 34 public:
35 explicit ProfilePolicyConnector(Profile* profile); 35 explicit ProfilePolicyConnector(Profile* profile);
36 virtual ~ProfilePolicyConnector(); 36 virtual ~ProfilePolicyConnector();
37 37
38 // If |force_immediate_load| then disk caches will be loaded synchronously. 38 // If |force_immediate_load| then disk caches will be loaded synchronously.
39 void Init(bool force_immediate_load, 39 void Init(bool force_immediate_load,
40 base::SequencedTaskRunner* sequenced_task_runner); 40 base::SequencedTaskRunner* sequenced_task_runner);
41 41
42 void InitForTesting(scoped_ptr<PolicyService> service); 42 void InitForTesting(scoped_ptr<PolicyService> service);
43 43
44 // ProfileKeyedService: 44 // BrowserContextKeyedService:
45 virtual void Shutdown() OVERRIDE; 45 virtual void Shutdown() OVERRIDE;
46 46
47 // This is never NULL. 47 // This is never NULL.
48 PolicyService* policy_service() const { return policy_service_.get(); } 48 PolicyService* policy_service() const { return policy_service_.get(); }
49 49
50 #if defined(ENABLE_MANAGED_USERS) && defined(ENABLE_CONFIGURATION_POLICY) 50 #if defined(ENABLE_MANAGED_USERS) && defined(ENABLE_CONFIGURATION_POLICY)
51 ManagedModePolicyProvider* managed_mode_policy_provider() const { 51 ManagedModePolicyProvider* managed_mode_policy_provider() const {
52 return managed_mode_policy_provider_.get(); 52 return managed_mode_policy_provider_.get();
53 } 53 }
54 #endif 54 #endif
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 #endif // ENABLE_CONFIGURATION_POLICY 94 #endif // ENABLE_CONFIGURATION_POLICY
95 95
96 scoped_ptr<PolicyService> policy_service_; 96 scoped_ptr<PolicyService> policy_service_;
97 97
98 DISALLOW_COPY_AND_ASSIGN(ProfilePolicyConnector); 98 DISALLOW_COPY_AND_ASSIGN(ProfilePolicyConnector);
99 }; 99 };
100 100
101 } // namespace policy 101 } // namespace policy
102 102
103 #endif // CHROME_BROWSER_POLICY_PROFILE_POLICY_CONNECTOR_H_ 103 #endif // CHROME_BROWSER_POLICY_PROFILE_POLICY_CONNECTOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698