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

Unified Diff: components/flags_ui/flags_state.h

Issue 2036193002: Allow overriding variation parameter via chrome://flags. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Build deps #2 Created 4 years, 6 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
« no previous file with comments | « components/flags_ui/feature_entry_macros.h ('k') | components/flags_ui/flags_state.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/flags_ui/flags_state.h
diff --git a/components/flags_ui/flags_state.h b/components/flags_ui/flags_state.h
index e7d2ac18e2f8062f503b401e1ec083bb1541b8bb..6f0ff1f87c865a5ddaa587a9c2d7c10ac50613ff 100644
--- a/components/flags_ui/flags_state.h
+++ b/components/flags_ui/flags_state.h
@@ -21,6 +21,13 @@ class ListValue;
namespace flags_ui {
+// Internal functionality exposed for tests.
+namespace internal {
+// The trial group selected when feature variation parameters are registered via
+// FlagsState::RegisterFeatureVariationParameters().
+extern const char kTrialGroupAboutFlags[];
+} // namespace internal
+
struct FeatureEntry;
class FlagsStorage;
struct SwitchEntry;
@@ -56,6 +63,9 @@ class FlagsState {
FlagsState(const FeatureEntry* feature_entries, size_t num_feature_entries);
~FlagsState();
+ // Reads the state from |flags_storage| and adds the command line flags
+ // belonging to the active feature entries to |command_line|. Features are
+ // appended via |enable_features_flag_name| and |disable_features_flag_name|.
void ConvertFlagsToSwitches(FlagsStorage* flags_storage,
base::CommandLine* command_line,
SentinelsMode sentinels,
@@ -70,6 +80,10 @@ class FlagsState {
void ResetAllFlags(FlagsStorage* flags_storage);
void Reset();
+ // Registers variations parameter values stored in |flags_storage| (previously
+ // selected in about:flags).
+ void RegisterAllFeatureVariationParameters(FlagsStorage* flags_storage);
+
// Gets the list of feature entries. Entries that are available for the
// current platform are appended to |supported_entries|; all other entries are
// appended to |unsupported_entries|.
« no previous file with comments | « components/flags_ui/feature_entry_macros.h ('k') | components/flags_ui/flags_state.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698