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

Side by Side Diff: components/variations/variations_seed_processor.cc

Issue 543893002: Random fixes through Chrome for scoped_reftpr T* removal. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "components/variations/variations_seed_processor.h" 5 #include "components/variations/variations_seed_processor.h"
6 6
7 #include <map> 7 #include <map>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
108 const Study_Experiment& experiment = study.experiment(i); 108 const Study_Experiment& experiment = study.experiment(i);
109 if (experiment.has_forcing_flag() && 109 if (experiment.has_forcing_flag() &&
110 command_line->HasSwitch(experiment.forcing_flag())) { 110 command_line->HasSwitch(experiment.forcing_flag())) {
111 scoped_refptr<base::FieldTrial> trial( 111 scoped_refptr<base::FieldTrial> trial(
112 base::FieldTrialList::CreateFieldTrial(study.name(), 112 base::FieldTrialList::CreateFieldTrial(study.name(),
113 experiment.name())); 113 experiment.name()));
114 // If |trial| is NULL, then there might already be a trial forced to a 114 // If |trial| is NULL, then there might already be a trial forced to a
115 // different group (e.g. via --force-fieldtrials). Break out of the loop, 115 // different group (e.g. via --force-fieldtrials). Break out of the loop,
116 // but don't return, so that variation ids and params for the selected 116 // but don't return, so that variation ids and params for the selected
117 // group will still be picked up. 117 // group will still be picked up.
118 if (!trial) 118 if (!trial.get())
119 break; 119 break;
120 120
121 RegisterExperimentParams(study, experiment); 121 RegisterExperimentParams(study, experiment);
122 RegisterVariationIds(experiment, study.name()); 122 RegisterVariationIds(experiment, study.name());
123 if (study.activation_type() == Study_ActivationType_ACTIVATION_AUTO) { 123 if (study.activation_type() == Study_ActivationType_ACTIVATION_AUTO) {
124 trial->group(); 124 trial->group();
125 // UI Strings can only be overridden from ACTIVATION_AUTO experiments. 125 // UI Strings can only be overridden from ACTIVATION_AUTO experiments.
126 ApplyUIStringOverrides(experiment, override_callback); 126 ApplyUIStringOverrides(experiment, override_callback);
127 } 127 }
128 128
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 // The field trial was defined from |study|, so the active experiment's name 187 // The field trial was defined from |study|, so the active experiment's name
188 // must be in the |study|. 188 // must be in the |study|.
189 DCHECK_NE(-1, experiment_index); 189 DCHECK_NE(-1, experiment_index);
190 190
191 ApplyUIStringOverrides(study.experiment(experiment_index), 191 ApplyUIStringOverrides(study.experiment(experiment_index),
192 override_callback); 192 override_callback);
193 } 193 }
194 } 194 }
195 195
196 } // namespace variations 196 } // namespace variations
OLDNEW
« no previous file with comments | « chrome/browser/ui/app_list/search/history_data_store.cc ('k') | device/usb/usb_device_handle_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698