| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_METRICS_METRICS_REPORTING_STATE_H_ | 5 #ifndef CHROME_BROWSER_METRICS_METRICS_REPORTING_STATE_H_ |
| 6 #define CHROME_BROWSER_METRICS_METRICS_REPORTING_STATE_H_ | 6 #define CHROME_BROWSER_METRICS_METRICS_REPORTING_STATE_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "components/metrics/metrics_service_client.h" | 9 #include "components/metrics/metrics_service_client.h" |
| 10 | 10 |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 | 25 |
| 26 // Update metrics prefs on a permission (opt-in/out) change. When opting out, | 26 // Update metrics prefs on a permission (opt-in/out) change. When opting out, |
| 27 // this clears various client ids. When opting in, this resets saving crash | 27 // this clears various client ids. When opting in, this resets saving crash |
| 28 // prefs, so as not to trigger upload of various stale data. | 28 // prefs, so as not to trigger upload of various stale data. |
| 29 void UpdateMetricsPrefsOnPermissionChange(bool metrics_enabled); | 29 void UpdateMetricsPrefsOnPermissionChange(bool metrics_enabled); |
| 30 | 30 |
| 31 // Returns whether MetricsReporting can be modified by the user (except | 31 // Returns whether MetricsReporting can be modified by the user (except |
| 32 // Android). | 32 // Android). |
| 33 bool IsMetricsReportingPolicyManaged(); | 33 bool IsMetricsReportingPolicyManaged(); |
| 34 | 34 |
| 35 // Initialize kMetricsReportingEnabled based on kStatsReportingPref device | |
| 36 // setting and add an observer as it is the source of truth on Chrome OS. | |
| 37 void SetupMetricsStateForChromeOS(); | |
| 38 | |
| 39 #endif // CHROME_BROWSER_METRICS_METRICS_REPORTING_STATE_H_ | 35 #endif // CHROME_BROWSER_METRICS_METRICS_REPORTING_STATE_H_ |
| OLD | NEW |