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

Side by Side Diff: chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h

Issue 751703003: Implemented consumer management unenrollment. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@dcpm
Patch Set: Rebase. Created 5 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_
6 #define CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ 6 #define CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 // to free the attributes. 130 // to free the attributes.
131 static void SetInstallAttributesForTesting( 131 static void SetInstallAttributesForTesting(
132 EnterpriseInstallAttributes* attributes); 132 EnterpriseInstallAttributes* attributes);
133 static void RemoveInstallAttributesForTesting(); 133 static void RemoveInstallAttributesForTesting();
134 134
135 // Registers device refresh rate pref. 135 // Registers device refresh rate pref.
136 static void RegisterPrefs(PrefRegistrySimple* registry); 136 static void RegisterPrefs(PrefRegistrySimple* registry);
137 137
138 // DeviceCloudPolicyManagerChromeOS::Observer: 138 // DeviceCloudPolicyManagerChromeOS::Observer:
139 void OnDeviceCloudPolicyManagerConnected() override; 139 void OnDeviceCloudPolicyManagerConnected() override;
140 void OnDeviceCloudPolicyManagerDisconnected() override;
140 141
141 private: 142 private:
142 // Set the timezone as soon as the policies are available. 143 // Set the timezone as soon as the policies are available.
143 void SetTimezoneIfPolicyAvailable(); 144 void SetTimezoneIfPolicyAvailable();
144 145
146 // Restarts the device cloud policy initializer, because the device's
147 // registration status changed from registered to unregistered.
148 void RestartDeviceCloudPolicyInitializer();
149
145 // Components of the device cloud policy implementation. 150 // Components of the device cloud policy implementation.
146 scoped_ptr<ServerBackedStateKeysBroker> state_keys_broker_; 151 scoped_ptr<ServerBackedStateKeysBroker> state_keys_broker_;
147 scoped_ptr<EnterpriseInstallAttributes> install_attributes_; 152 scoped_ptr<EnterpriseInstallAttributes> install_attributes_;
148 scoped_ptr<ConsumerManagementService> consumer_management_service_; 153 scoped_ptr<ConsumerManagementService> consumer_management_service_;
149 DeviceCloudPolicyManagerChromeOS* device_cloud_policy_manager_; 154 DeviceCloudPolicyManagerChromeOS* device_cloud_policy_manager_;
155 PrefService* local_state_;
150 scoped_ptr<DeviceManagementService> consumer_device_management_service_; 156 scoped_ptr<DeviceManagementService> consumer_device_management_service_;
151 scoped_ptr<DeviceCloudPolicyInitializer> device_cloud_policy_initializer_; 157 scoped_ptr<DeviceCloudPolicyInitializer> device_cloud_policy_initializer_;
152 scoped_ptr<DeviceLocalAccountPolicyService> 158 scoped_ptr<DeviceLocalAccountPolicyService>
153 device_local_account_policy_service_; 159 device_local_account_policy_service_;
154 scoped_ptr<DeviceCloudPolicyInvalidator> device_cloud_policy_invalidator_; 160 scoped_ptr<DeviceCloudPolicyInvalidator> device_cloud_policy_invalidator_;
155 161
156 // This policy provider is used on Chrome OS to feed user policy into the 162 // This policy provider is used on Chrome OS to feed user policy into the
157 // global PolicyService instance. This works by installing the cloud policy 163 // global PolicyService instance. This works by installing the cloud policy
158 // provider of the primary profile as the delegate of the ProxyPolicyProvider, 164 // provider of the primary profile as the delegate of the ProxyPolicyProvider,
159 // after login. 165 // after login.
160 // The provider is owned by the base class; this field is just a typed weak 166 // The provider is owned by the base class; this field is just a typed weak
161 // pointer to get to the ProxyPolicyProvider at SetUserPolicyDelegate(). 167 // pointer to get to the ProxyPolicyProvider at SetUserPolicyDelegate().
162 ProxyPolicyProvider* global_user_cloud_policy_provider_; 168 ProxyPolicyProvider* global_user_cloud_policy_provider_;
163 169
164 scoped_ptr<NetworkConfigurationUpdater> network_configuration_updater_; 170 scoped_ptr<NetworkConfigurationUpdater> network_configuration_updater_;
165 171
166 base::WeakPtrFactory<BrowserPolicyConnectorChromeOS> weak_ptr_factory_; 172 base::WeakPtrFactory<BrowserPolicyConnectorChromeOS> weak_ptr_factory_;
167 173
168 DISALLOW_COPY_AND_ASSIGN(BrowserPolicyConnectorChromeOS); 174 DISALLOW_COPY_AND_ASSIGN(BrowserPolicyConnectorChromeOS);
169 }; 175 };
170 176
171 } // namespace policy 177 } // namespace policy
172 178
173 #endif // CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_ 179 #endif // CHROME_BROWSER_CHROMEOS_POLICY_BROWSER_POLICY_CONNECTOR_CHROMEOS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698