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

Unified Diff: chrome/browser/metrics/chrome_metrics_service_accessor.h

Issue 506663003: Consolidates accessing and setting the UMA pref to be within metrics code (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix and rollback unnecessary changes Created 6 years, 3 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: chrome/browser/metrics/chrome_metrics_service_accessor.h
diff --git a/chrome/browser/metrics/chrome_metrics_service_accessor.h b/chrome/browser/metrics/chrome_metrics_service_accessor.h
index d64f4c6f561b026279bdb10238c57bc454bfee61..0493d6d1559970edfd50d8db853709c5fd96a414 100644
--- a/chrome/browser/metrics/chrome_metrics_service_accessor.h
+++ b/chrome/browser/metrics/chrome_metrics_service_accessor.h
@@ -8,6 +8,7 @@
#include <stdint.h>
#include <string>
+#include "base/callback.h"
#include "base/gtest_prod_util.h"
#include "base/macros.h"
#include "chrome/browser/metrics/metrics_service_accessor.h"
@@ -33,6 +34,10 @@ namespace system_logs {
class ChromeInternalLogSource;
}
+namespace options {
+class BrowserOptionsHandler;
+}
+
// This class limits and documents access to metrics service helper methods.
// Since these methods are private, each user has to be explicitly declared
// as a 'friend' below.
@@ -48,6 +53,9 @@ class ChromeMetricsServiceAccessor : public MetricsServiceAccessor {
friend class ::FlashDOMHandler;
friend class system_logs::ChromeInternalLogSource;
friend class UmaSessionStats;
+ friend class options::BrowserOptionsHandler;
+ friend void InitiateMetricsReportingChange(bool,
+ const base::Callback<void(bool)>);
FRIEND_TEST_ALL_PREFIXES(ChromeMetricsServiceAccessorTest,
MetricsReportingEnabled);

Powered by Google App Engine
This is Rietveld 408576698