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

Unified Diff: components/flags_ui/flags_state.cc

Issue 2231753002: components: Use stl utilities from the base namespace (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: One more call site Created 4 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
« no previous file with comments | « components/feedback/feedback_uploader_unittest.cc ('k') | components/flags_ui/flags_state_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/flags_ui/flags_state.cc
diff --git a/components/flags_ui/flags_state.cc b/components/flags_ui/flags_state.cc
index c3d992b11b4b933272f07f7fff2af12f50948e26..e0f1593b4543b1f5a1c81272113cce4bb7aeacc6 100644
--- a/components/flags_ui/flags_state.cc
+++ b/components/flags_ui/flags_state.cc
@@ -404,7 +404,7 @@ void FlagsState::RemoveFlagsSwitches(
// For any featrue name in |features| that is not in |switch_added_values| -
// i.e. it wasn't added by about_flags code, add it to |remaining_features|.
for (const std::string& feature : features) {
- if (!ContainsKey(switch_added_values, feature))
+ if (!base::ContainsKey(switch_added_values, feature))
remaining_features.push_back(feature);
}
@@ -592,7 +592,7 @@ void FlagsState::AddSwitchMapping(
const std::string& switch_name,
const std::string& switch_value,
std::map<std::string, SwitchEntry>* name_to_switch_map) {
- DCHECK(!ContainsKey(*name_to_switch_map, key));
+ DCHECK(!base::ContainsKey(*name_to_switch_map, key));
SwitchEntry* entry = &(*name_to_switch_map)[key];
entry->switch_name = switch_name;
@@ -604,7 +604,7 @@ void FlagsState::AddFeatureMapping(
const std::string& feature_name,
bool feature_state,
std::map<std::string, SwitchEntry>* name_to_switch_map) {
- DCHECK(!ContainsKey(*name_to_switch_map, key));
+ DCHECK(!base::ContainsKey(*name_to_switch_map, key));
SwitchEntry* entry = &(*name_to_switch_map)[key];
entry->feature_name = feature_name;
@@ -665,11 +665,11 @@ void FlagsState::MergeFeatureCommandLineSwitch(
std::vector<std::string> features =
base::FeatureList::SplitFeatureListString(original_switch_value);
// Only add features that don't already exist in the lists.
- // Note: The ContainsValue() call results in O(n^2) performance, but in
+ // Note: The base::ContainsValue() call results in O(n^2) performance, but in
// practice n should be very small.
for (const auto& entry : feature_switches) {
if (entry.second == feature_state &&
- !ContainsValue(features, entry.first)) {
+ !base::ContainsValue(features, entry.first)) {
features.push_back(entry.first);
appended_switches_[switch_name].insert(entry.first);
}
« no previous file with comments | « components/feedback/feedback_uploader_unittest.cc ('k') | components/flags_ui/flags_state_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698