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

Unified Diff: content/public/browser/user_metrics.h

Issue 12039079: content: convert user action notification to observer usage (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixes Created 7 years, 11 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: content/public/browser/user_metrics.h
diff --git a/content/public/browser/user_metrics.h b/content/public/browser/user_metrics.h
index d1f39bfb63d9cb20afd9497b471f08b0b70e720c..1bf2f1ce5ca5e56f2d9f16f26ec89bdfc2d93a9a 100644
--- a/content/public/browser/user_metrics.h
+++ b/content/public/browser/user_metrics.h
@@ -7,6 +7,8 @@
#include <string>
+#include "base/callback.h"
+#include "base/threading/non_thread_safe.h"
jam 2013/01/31 21:41:55 nit: not needed
Paweł Hajdan Jr. 2013/02/01 10:43:57 Done.
#include "content/common/content_export.h"
namespace content {
@@ -50,6 +52,13 @@ CONTENT_EXPORT void RecordAction(const UserMetricsAction& action);
// chrome/tools/extract_actions.py.
CONTENT_EXPORT void RecordComputedAction(const std::string& action);
+// Called with the action string.
+typedef base::Callback<void(const std::string&)> ActionCallback;
+
+// Add/remove action callbacks (see above).
+CONTENT_EXPORT void AddActionCallback(const ActionCallback& callback);
+CONTENT_EXPORT void RemoveActionCallback(const ActionCallback& callback);
+
} // namespace content
#endif // CONTENT_PUBLIC_BROWSER_USER_METRICS_H_
« content/browser/user_metrics.cc ('K') | « content/public/browser/notification_types.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698