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

Unified Diff: base/metrics/user_metrics.h

Issue 1859213002: Move the thread hop for UMA user actions from content:: to base::. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing bugs. Created 4 years, 8 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
Index: base/metrics/user_metrics.h
diff --git a/base/metrics/user_metrics.h b/base/metrics/user_metrics.h
index bcfefb809942e203590dfd9db7672cc56f861c7c..acfecd696dc69ac06e6a023990e78ee3b6af3d4b 100644
--- a/base/metrics/user_metrics.h
+++ b/base/metrics/user_metrics.h
@@ -10,6 +10,7 @@
#include "base/base_export.h"
#include "base/callback.h"
#include "base/metrics/user_metrics_action.h"
+#include "base/single_thread_task_runner.h"
namespace base {
@@ -55,6 +56,11 @@ typedef base::Callback<void(const std::string&)> ActionCallback;
BASE_EXPORT void AddActionCallback(const ActionCallback& callback);
BASE_EXPORT void RemoveActionCallback(const ActionCallback& callback);
+// Set the task runner on which to record actions. The task runner can only be
+// set once, unless ResetRecordActionTaskRunnerForTesting is called.
sgurun-gerrit only 2016/04/19 15:36:06 is it optional to call this? if not called what is
beaudoin 2016/04/19 16:57:27 Must be called before any of the other functions h
+BASE_EXPORT void SetRecordActionTaskRunner(
+ scoped_refptr<base::SingleThreadTaskRunner> task_runner);
+
} // namespace base
#endif // BASE_METRICS_USER_METRICS_H_

Powered by Google App Engine
This is Rietveld 408576698