| 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 #include "chrome/browser/chromeos/policy/device_cloud_policy_manager_chromeos.h" | 5 #include "chrome/browser/chromeos/policy/device_cloud_policy_manager_chromeos.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 309 local_state_->SetBoolean( | 309 local_state_->SetBoolean( |
| 310 prefs::kDeviceEnrollmentCanExit, | 310 prefs::kDeviceEnrollmentCanExit, |
| 311 GetMachineFlag(chromeos::system::kOemCanExitEnterpriseEnrollmentKey, | 311 GetMachineFlag(chromeos::system::kOemCanExitEnterpriseEnrollmentKey, |
| 312 false)); | 312 false)); |
| 313 } | 313 } |
| 314 } | 314 } |
| 315 } | 315 } |
| 316 } | 316 } |
| 317 | 317 |
| 318 void DeviceCloudPolicyManagerChromeOS::NotifyConnected() { | 318 void DeviceCloudPolicyManagerChromeOS::NotifyConnected() { |
| 319 FOR_EACH_OBSERVER( | 319 for (auto& observer : observers_) |
| 320 Observer, observers_, OnDeviceCloudPolicyManagerConnected()); | 320 observer.OnDeviceCloudPolicyManagerConnected(); |
| 321 } | 321 } |
| 322 | 322 |
| 323 void DeviceCloudPolicyManagerChromeOS::NotifyDisconnected() { | 323 void DeviceCloudPolicyManagerChromeOS::NotifyDisconnected() { |
| 324 FOR_EACH_OBSERVER( | 324 for (auto& observer : observers_) |
| 325 Observer, observers_, OnDeviceCloudPolicyManagerDisconnected()); | 325 observer.OnDeviceCloudPolicyManagerDisconnected(); |
| 326 } | 326 } |
| 327 | 327 |
| 328 void DeviceCloudPolicyManagerChromeOS::CreateStatusUploader() { | 328 void DeviceCloudPolicyManagerChromeOS::CreateStatusUploader() { |
| 329 status_uploader_.reset(new StatusUploader( | 329 status_uploader_.reset(new StatusUploader( |
| 330 client(), | 330 client(), |
| 331 base::MakeUnique<DeviceStatusCollector>( | 331 base::MakeUnique<DeviceStatusCollector>( |
| 332 local_state_, chromeos::system::StatisticsProvider::GetInstance(), | 332 local_state_, chromeos::system::StatisticsProvider::GetInstance(), |
| 333 DeviceStatusCollector::VolumeInfoFetcher(), | 333 DeviceStatusCollector::VolumeInfoFetcher(), |
| 334 DeviceStatusCollector::CPUStatisticsFetcher(), | 334 DeviceStatusCollector::CPUStatisticsFetcher(), |
| 335 DeviceStatusCollector::CPUTempFetcher(), | 335 DeviceStatusCollector::CPUTempFetcher(), |
| 336 DeviceStatusCollector::AndroidStatusFetcher()), | 336 DeviceStatusCollector::AndroidStatusFetcher()), |
| 337 task_runner_)); | 337 task_runner_)); |
| 338 } | 338 } |
| 339 | 339 |
| 340 } // namespace policy | 340 } // namespace policy |
| OLD | NEW |