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/policy/device_policy_cache.cc

Issue 8585025: chromeos: Change all clients of UpdateLibrary to use UpdateEngineClient. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: address comments Created 9 years, 1 month 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
« no previous file with comments | « chrome/browser/chromeos/upgrade_detector_chromeos.cc ('k') | chrome/browser/ui/browser_list.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/device_policy_cache.h" 5 #include "chrome/browser/policy/device_policy_cache.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
11 #include "base/basictypes.h" 11 #include "base/basictypes.h"
12 #include "base/bind.h" 12 #include "base/bind.h"
13 #include "base/callback.h" 13 #include "base/callback.h"
14 #include "base/compiler_specific.h" 14 #include "base/compiler_specific.h"
15 #include "base/logging.h" 15 #include "base/logging.h"
16 #include "base/metrics/histogram.h" 16 #include "base/metrics/histogram.h"
17 #include "base/values.h" 17 #include "base/values.h"
18 #include "chrome/browser/chromeos/cros/cros_library.h" 18 #include "chrome/browser/chromeos/dbus/dbus_thread_manager.h"
19 #include "chrome/browser/chromeos/cros/update_library.h" 19 #include "chrome/browser/chromeos/dbus/update_engine_client.h"
20 #include "chrome/browser/chromeos/login/ownership_service.h" 20 #include "chrome/browser/chromeos/login/ownership_service.h"
21 #include "chrome/browser/chromeos/user_cros_settings_provider.h" 21 #include "chrome/browser/chromeos/user_cros_settings_provider.h"
22 #include "chrome/browser/policy/cloud_policy_data_store.h" 22 #include "chrome/browser/policy/cloud_policy_data_store.h"
23 #include "chrome/browser/policy/enterprise_install_attributes.h" 23 #include "chrome/browser/policy/enterprise_install_attributes.h"
24 #include "chrome/browser/policy/enterprise_metrics.h" 24 #include "chrome/browser/policy/enterprise_metrics.h"
25 #include "chrome/browser/policy/policy_map.h" 25 #include "chrome/browser/policy/policy_map.h"
26 #include "chrome/browser/policy/proto/device_management_backend.pb.h" 26 #include "chrome/browser/policy/proto/device_management_backend.pb.h"
27 #include "chrome/browser/policy/proto/device_management_constants.h" 27 #include "chrome/browser/policy/proto/device_management_constants.h"
28 #include "chrome/browser/policy/proto/device_management_local.pb.h" 28 #include "chrome/browser/policy/proto/device_management_local.pb.h"
29 #include "policy/configuration_policy_type.h" 29 #include "policy/configuration_policy_type.h"
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 } 343 }
344 344
345 if (policy.has_release_channel() && 345 if (policy.has_release_channel() &&
346 policy.release_channel().has_release_channel()) { 346 policy.release_channel().has_release_channel()) {
347 std::string channel(policy.release_channel().release_channel()); 347 std::string channel(policy.release_channel().release_channel());
348 mandatory->Set(kPolicyChromeOsReleaseChannel, 348 mandatory->Set(kPolicyChromeOsReleaseChannel,
349 Value::CreateStringValue(channel)); 349 Value::CreateStringValue(channel));
350 // TODO(dubroy): Once http://crosbug.com/17015 is implemented, we won't 350 // TODO(dubroy): Once http://crosbug.com/17015 is implemented, we won't
351 // have to pass the channel in here, only ping the update engine to tell 351 // have to pass the channel in here, only ping the update engine to tell
352 // it to fetch the channel from the policy. 352 // it to fetch the channel from the policy.
353 chromeos::CrosLibrary::Get()->GetUpdateLibrary()->SetReleaseTrack(channel); 353 chromeos::DBusThreadManager::Get()->GetUpdateEngineClient()
354 ->SetReleaseTrack(channel);
354 } 355 }
355 356
356 if (policy.has_open_network_configuration() && 357 if (policy.has_open_network_configuration() &&
357 policy.open_network_configuration().has_open_network_configuration()) { 358 policy.open_network_configuration().has_open_network_configuration()) {
358 std::string config( 359 std::string config(
359 policy.open_network_configuration().open_network_configuration()); 360 policy.open_network_configuration().open_network_configuration());
360 mandatory->Set(kPolicyDeviceOpenNetworkConfiguration, 361 mandatory->Set(kPolicyDeviceOpenNetworkConfiguration,
361 Value::CreateStringValue(config)); 362 Value::CreateStringValue(config));
362 } 363 }
363 } 364 }
364 365
365 } // namespace policy 366 } // namespace policy
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/upgrade_detector_chromeos.cc ('k') | chrome/browser/ui/browser_list.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698