OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" | 5 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" |
6 | 6 |
7 #include "base/prefs/pref_service.h" | 7 #include "base/prefs/pref_service.h" |
8 #include "chrome/browser/browser_process.h" | 8 #include "chrome/browser/browser_process.h" |
9 #include "chrome/common/pref_names.h" | 9 #include "chrome/common/pref_names.h" |
10 #include "components/metrics/metrics_service.h" | 10 #include "components/metrics/metrics_service.h" |
(...skipping 28 matching lines...) Expand all Loading... |
39 // Android has its own settings for metrics / crash uploading. | 39 // Android has its own settings for metrics / crash uploading. |
40 const PrefService* prefs = g_browser_process->local_state(); | 40 const PrefService* prefs = g_browser_process->local_state(); |
41 return prefs->GetBoolean(prefs::kCrashReportingEnabled); | 41 return prefs->GetBoolean(prefs::kCrashReportingEnabled); |
42 #else | 42 #else |
43 return ChromeMetricsServiceAccessor::IsMetricsReportingEnabled(); | 43 return ChromeMetricsServiceAccessor::IsMetricsReportingEnabled(); |
44 #endif | 44 #endif |
45 #else | 45 #else |
46 return false; | 46 return false; |
47 #endif | 47 #endif |
48 } | 48 } |
| 49 |
| 50 // static |
| 51 bool ChromeMetricsServiceAccessor::RegisterSyntheticFieldTrial( |
| 52 const std::string& trial, const std::string& group) { |
| 53 return MetricsServiceAccessor::RegisterSyntheticFieldTrial( |
| 54 g_browser_process->metrics_service(), |
| 55 trial, |
| 56 group); |
| 57 } |
OLD | NEW |