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

Unified Diff: chrome/browser/metrics/metrics_service_accessor.cc

Issue 440693002: Add function to register a synthetic trial with the trial hash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 6 years, 4 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/metrics_service_accessor.cc
===================================================================
--- chrome/browser/metrics/metrics_service_accessor.cc (revision 287334)
+++ chrome/browser/metrics/metrics_service_accessor.cc (working copy)
@@ -7,7 +7,6 @@
#include "chrome/browser/browser_process.h"
#include "components/metrics/metrics_service.h"
#include "components/metrics/metrics_service_observer.h"
-#include "components/variations/metrics_util.h"
// static
void MetricsServiceAccessor::AddMetricsServiceObserver(
@@ -27,13 +26,12 @@
// static
bool MetricsServiceAccessor::RegisterSyntheticFieldTrial(
MetricsService* metrics_service,
- const std::string& trial,
- const std::string& group) {
+ uint32_t trial_name_hash,
+ uint32_t group_name_hash) {
if (!metrics_service)
return false;
- SyntheticTrialGroup trial_group(metrics::HashName(trial),
- metrics::HashName(group));
+ SyntheticTrialGroup trial_group(trial_name_hash, group_name_hash);
metrics_service->RegisterSyntheticFieldTrial(trial_group);
return true;
}

Powered by Google App Engine
This is Rietveld 408576698