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

Unified Diff: components/metrics/metrics_service.cc

Issue 1530133005: Refactor VariationsHttpHeaderProvider. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add missing include to srt_fetcher_win.cc. Created 5 years 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
« no previous file with comments | « components/metrics/metrics_service.h ('k') | components/metrics/metrics_service_accessor.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/metrics/metrics_service.cc
diff --git a/components/metrics/metrics_service.cc b/components/metrics/metrics_service.cc
index 55aa9f10c8c0daaf3e0a764020602c5e3d7c5d1b..f84deafaa1bc9683e01fbaade63069bf0511fa0f 100644
--- a/components/metrics/metrics_service.cc
+++ b/components/metrics/metrics_service.cc
@@ -242,15 +242,6 @@ bool ShouldUploadLog() {
} // namespace
-
-SyntheticTrialGroup::SyntheticTrialGroup(uint32 trial, uint32 group) {
- id.name = trial;
- id.group = group;
-}
-
-SyntheticTrialGroup::~SyntheticTrialGroup() {
-}
-
// static
MetricsService::ShutdownCleanliness MetricsService::clean_shutdown_status_ =
MetricsService::CLEANLY_SHUTDOWN;
@@ -1025,19 +1016,19 @@ bool MetricsService::UmaMetricsProperlyShutdown() {
}
void MetricsService::AddSyntheticTrialObserver(
- SyntheticTrialObserver* observer) {
+ variations::SyntheticTrialObserver* observer) {
synthetic_trial_observer_list_.AddObserver(observer);
if (!synthetic_trial_groups_.empty())
observer->OnSyntheticTrialsChanged(synthetic_trial_groups_);
}
void MetricsService::RemoveSyntheticTrialObserver(
- SyntheticTrialObserver* observer) {
+ variations::SyntheticTrialObserver* observer) {
synthetic_trial_observer_list_.RemoveObserver(observer);
}
void MetricsService::RegisterSyntheticFieldTrial(
- const SyntheticTrialGroup& trial) {
+ const variations::SyntheticTrialGroup& trial) {
for (size_t i = 0; i < synthetic_trial_groups_.size(); ++i) {
if (synthetic_trial_groups_[i].id.name == trial.id.name) {
if (synthetic_trial_groups_[i].id.group != trial.id.group) {
@@ -1049,7 +1040,7 @@ void MetricsService::RegisterSyntheticFieldTrial(
}
}
- SyntheticTrialGroup trial_group = trial;
+ variations::SyntheticTrialGroup trial_group = trial;
trial_group.start_time = base::TimeTicks::Now();
synthetic_trial_groups_.push_back(trial_group);
NotifySyntheticTrialObservers();
@@ -1072,7 +1063,8 @@ void MetricsService::CheckForClonedInstall(
}
void MetricsService::NotifySyntheticTrialObservers() {
- FOR_EACH_OBSERVER(SyntheticTrialObserver, synthetic_trial_observer_list_,
+ FOR_EACH_OBSERVER(variations::SyntheticTrialObserver,
+ synthetic_trial_observer_list_,
OnSyntheticTrialsChanged(synthetic_trial_groups_));
}
« no previous file with comments | « components/metrics/metrics_service.h ('k') | components/metrics/metrics_service_accessor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698