| 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/policy/browser_policy_connector.h" | 5 #include "chrome/browser/policy/browser_policy_connector.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
| (...skipping 563 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 574 device_data_store_->set_machine_model( | 574 device_data_store_->set_machine_model( |
| 575 DeviceCloudPolicyManagerChromeOS::GetMachineModel()); | 575 DeviceCloudPolicyManagerChromeOS::GetMachineModel()); |
| 576 } | 576 } |
| 577 | 577 |
| 578 device_cloud_policy_subsystem_->CompleteInitialization( | 578 device_cloud_policy_subsystem_->CompleteInitialization( |
| 579 prefs::kDevicePolicyRefreshRate, | 579 prefs::kDevicePolicyRefreshRate, |
| 580 kServiceInitializationStartupDelay); | 580 kServiceInitializationStartupDelay); |
| 581 } | 581 } |
| 582 | 582 |
| 583 if (device_data_store_.get()) { | 583 if (device_data_store_.get()) { |
| 584 device_data_store_->set_device_status_collector( | 584 DeviceStatusCollector* collector = |
| 585 new DeviceStatusCollector( | 585 new DeviceStatusCollector( |
| 586 g_browser_process->local_state(), | 586 g_browser_process->local_state(), |
| 587 chromeos::system::StatisticsProvider::GetInstance(), | 587 chromeos::system::StatisticsProvider::GetInstance(), |
| 588 NULL)); | 588 NULL); |
| 589 collector->Init(); |
| 590 device_data_store_->set_device_status_collector(collector); |
| 589 } | 591 } |
| 590 | 592 |
| 591 if (device_cloud_policy_manager_.get()) { | 593 if (device_cloud_policy_manager_.get()) { |
| 592 device_cloud_policy_manager_->Init(); | 594 device_cloud_policy_manager_->Init(); |
| 593 device_cloud_policy_manager_->Connect( | 595 device_cloud_policy_manager_->Connect( |
| 594 g_browser_process->local_state(), | 596 g_browser_process->local_state(), |
| 595 device_management_service_.get()); | 597 device_management_service_.get()); |
| 596 } | 598 } |
| 597 | 599 |
| 598 SetTimezoneIfPolicyAvailable(); | 600 SetTimezoneIfPolicyAvailable(); |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 672 return new AsyncPolicyProvider(loader.Pass()); | 674 return new AsyncPolicyProvider(loader.Pass()); |
| 673 } else { | 675 } else { |
| 674 return NULL; | 676 return NULL; |
| 675 } | 677 } |
| 676 #else | 678 #else |
| 677 return NULL; | 679 return NULL; |
| 678 #endif | 680 #endif |
| 679 } | 681 } |
| 680 | 682 |
| 681 } // namespace policy | 683 } // namespace policy |
| OLD | NEW |