Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_ABOUT_FLAGS_H_ | 5 #ifndef CHROME_BROWSER_ABOUT_FLAGS_H_ |
| 6 #define CHROME_BROWSER_ABOUT_FLAGS_H_ | 6 #define CHROME_BROWSER_ABOUT_FLAGS_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 100 std::string NameForChoice(int index) const; | 100 std::string NameForChoice(int index) const; |
| 101 | 101 |
| 102 // Returns the human readable description for the choice at |index|. | 102 // Returns the human readable description for the choice at |index|. |
| 103 string16 DescriptionForChoice(int index) const; | 103 string16 DescriptionForChoice(int index) const; |
| 104 }; | 104 }; |
| 105 | 105 |
| 106 // Reads the Labs |prefs| (called "Labs" for historical reasons) and adds the | 106 // Reads the Labs |prefs| (called "Labs" for historical reasons) and adds the |
| 107 // commandline flags belonging to the active experiments to |command_line|. | 107 // commandline flags belonging to the active experiments to |command_line|. |
| 108 void ConvertFlagsToSwitches(PrefService* prefs, CommandLine* command_line); | 108 void ConvertFlagsToSwitches(PrefService* prefs, CommandLine* command_line); |
| 109 | 109 |
| 110 // Compares a set of switches of the two provided command line objects and | |
| 111 // returns true if they are the same and false otherwise. | |
| 112 bool CompareSwitchesToCurrentCommandLine(const CommandLine& new_cmdline, | |
|
Nico
2013/06/13 17:59:57
AreSwitchesIdenticalToCurrentCommandLine() makes i
pastarmovj
2013/06/14 11:40:38
Done.
| |
| 113 const CommandLine& active_cmdline); | |
| 114 | |
| 110 // Differentiate between generic flags available on a per session base and flags | 115 // Differentiate between generic flags available on a per session base and flags |
| 111 // that influence the whole machine and can be said by the admin only. This flag | 116 // that influence the whole machine and can be said by the admin only. This flag |
| 112 // is relevant for ChromeOS for now only and dictates whether entries marked | 117 // is relevant for ChromeOS for now only and dictates whether entries marked |
| 113 // with the |kOsCrOSOwnerOnly| label should be enabled in the UI or not. | 118 // with the |kOsCrOSOwnerOnly| label should be enabled in the UI or not. |
| 114 enum FlagAccess { kGeneralAccessFlagsOnly, kOwnerAccessToFlags }; | 119 enum FlagAccess { kGeneralAccessFlagsOnly, kOwnerAccessToFlags }; |
| 115 | 120 |
| 116 // Get the list of experiments. Experiments that are available on the current | 121 // Get the list of experiments. Experiments that are available on the current |
| 117 // platform are appended to |supported_experiments|; all other experiments are | 122 // platform are appended to |supported_experiments|; all other experiments are |
| 118 // appended to |unsupported_experiments|. | 123 // appended to |unsupported_experiments|. |
| 119 void GetFlagsExperimentsData(PrefService* prefs, | 124 void GetFlagsExperimentsData(PrefService* prefs, |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 159 | 164 |
| 160 // Separator used for multi values. Multi values are represented in prefs as | 165 // Separator used for multi values. Multi values are represented in prefs as |
| 161 // name-of-experiment + kMultiSeparator + selected_index. | 166 // name-of-experiment + kMultiSeparator + selected_index. |
| 162 extern const char kMultiSeparator[]; | 167 extern const char kMultiSeparator[]; |
| 163 | 168 |
| 164 } // namespace testing | 169 } // namespace testing |
| 165 | 170 |
| 166 } // namespace about_flags | 171 } // namespace about_flags |
| 167 | 172 |
| 168 #endif // CHROME_BROWSER_ABOUT_FLAGS_H_ | 173 #endif // CHROME_BROWSER_ABOUT_FLAGS_H_ |
| OLD | NEW |