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

Side by Side Diff: chrome/browser/chromeos/policy/device_status_collector.cc

Issue 25112004: Move statistics_provider to chromeos/system (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add comments Created 7 years, 2 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) 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_status_collector.h" 5 #include "chrome/browser/chromeos/policy/device_status_collector.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
11 #include "base/location.h" 11 #include "base/location.h"
12 #include "base/logging.h" 12 #include "base/logging.h"
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "base/prefs/pref_registry_simple.h" 14 #include "base/prefs/pref_registry_simple.h"
15 #include "base/prefs/pref_service.h" 15 #include "base/prefs/pref_service.h"
16 #include "base/strings/string_number_conversions.h" 16 #include "base/strings/string_number_conversions.h"
17 #include "base/values.h" 17 #include "base/values.h"
18 #include "chrome/browser/chromeos/settings/cros_settings.h" 18 #include "chrome/browser/chromeos/settings/cros_settings.h"
19 #include "chrome/browser/chromeos/settings/cros_settings_names.h" 19 #include "chrome/browser/chromeos/settings/cros_settings_names.h"
20 #include "chrome/browser/chromeos/system/statistics_provider.h"
21 #include "chrome/browser/policy/proto/cloud/device_management_backend.pb.h" 20 #include "chrome/browser/policy/proto/cloud/device_management_backend.pb.h"
22 #include "chrome/browser/prefs/scoped_user_pref_update.h" 21 #include "chrome/browser/prefs/scoped_user_pref_update.h"
23 #include "chrome/common/chrome_version_info.h" 22 #include "chrome/common/chrome_version_info.h"
24 #include "chrome/common/pref_names.h" 23 #include "chrome/common/pref_names.h"
25 #include "chromeos/network/device_state.h" 24 #include "chromeos/network/device_state.h"
26 #include "chromeos/network/network_handler.h" 25 #include "chromeos/network/network_handler.h"
27 #include "chromeos/network/network_state_handler.h" 26 #include "chromeos/network/network_state_handler.h"
27 #include "chromeos/system/statistics_provider.h"
28 #include "content/public/browser/browser_thread.h" 28 #include "content/public/browser/browser_thread.h"
29 #include "third_party/cros_system_api/dbus/service_constants.h" 29 #include "third_party/cros_system_api/dbus/service_constants.h"
30 30
31 using base::Time; 31 using base::Time;
32 using base::TimeDelta; 32 using base::TimeDelta;
33 using chromeos::VersionLoader; 33 using chromeos::VersionLoader;
34 34
35 namespace em = enterprise_management; 35 namespace em = enterprise_management;
36 36
37 namespace { 37 namespace {
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
542 location.SetDouble(kSpeed, position.speed); 542 location.SetDouble(kSpeed, position.speed);
543 location.SetString(kTimestamp, 543 location.SetString(kTimestamp,
544 base::Int64ToString(position.timestamp.ToInternalValue())); 544 base::Int64ToString(position.timestamp.ToInternalValue()));
545 local_state_->Set(prefs::kDeviceLocation, location); 545 local_state_->Set(prefs::kDeviceLocation, location);
546 } 546 }
547 547
548 ScheduleGeolocationUpdateRequest(); 548 ScheduleGeolocationUpdateRequest();
549 } 549 }
550 550
551 } // namespace policy 551 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698