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

Unified Diff: chrome/browser/metrics/cloned_install_detector.cc

Issue 292723004: Remove ClonedInstallDetector/MachineIdProvider //content dependencies (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix build Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/metrics/cloned_install_detector.h ('k') | chrome/browser/metrics/machine_id_provider_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/metrics/cloned_install_detector.cc
diff --git a/chrome/browser/metrics/cloned_install_detector.cc b/chrome/browser/metrics/cloned_install_detector.cc
index db52b842d1d84f256a6a5fcdd9293c0849c3c78b..b87c539c848887b2af66ee46df5069fc3de54885 100644
--- a/chrome/browser/metrics/cloned_install_detector.cc
+++ b/chrome/browser/metrics/cloned_install_detector.cc
@@ -5,14 +5,16 @@
#include "chrome/browser/metrics/cloned_install_detector.h"
#include "base/bind.h"
+#include "base/location.h"
#include "base/metrics/histogram.h"
#include "base/prefs/pref_registry_simple.h"
#include "base/prefs/pref_service.h"
+#include "base/single_thread_task_runner.h"
+#include "base/task_runner_util.h"
#include "chrome/browser/metrics/cloned_install_detector.h"
#include "chrome/browser/metrics/machine_id_provider.h"
#include "chrome/common/pref_names.h"
#include "components/metrics/metrics_hashes.h"
-#include "content/public/browser/browser_thread.h"
namespace metrics {
@@ -48,12 +50,13 @@ ClonedInstallDetector::ClonedInstallDetector(MachineIdProvider* raw_id_provider)
ClonedInstallDetector::~ClonedInstallDetector() {}
-void ClonedInstallDetector::CheckForClonedInstall(PrefService* local_state) {
- content::BrowserThread::PostTaskAndReplyWithResult(
- content::BrowserThread::FILE,
+void ClonedInstallDetector::CheckForClonedInstall(
+ PrefService* local_state,
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner) {
+ base::PostTaskAndReplyWithResult(
+ task_runner.get(),
FROM_HERE,
- base::Bind(&metrics::MachineIdProvider::GetMachineId,
- raw_id_provider_),
+ base::Bind(&metrics::MachineIdProvider::GetMachineId, raw_id_provider_),
base::Bind(&metrics::ClonedInstallDetector::SaveMachineId,
weak_ptr_factory_.GetWeakPtr(),
local_state));
« no previous file with comments | « chrome/browser/metrics/cloned_install_detector.h ('k') | chrome/browser/metrics/machine_id_provider_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698