diff options
author | Aaron Record <aaronjrecord@gmail.com> | 2022-05-18 17:43:40 -0600 |
---|---|---|
committer | Aaron Record <aaronjrecord@gmail.com> | 2022-05-19 12:09:16 +0200 |
commit | 900c676b0282bed83d00834e3c280ac89c2bc94d (patch) | |
tree | b6bf869a55440a666f4bcc17d5e9cd93ff26dbdc /core/config | |
parent | 71c40ff4da85a4770958533cdc65f2c9f7ddeaff (diff) |
Use range iterators for RBSet in most cases
Diffstat (limited to 'core/config')
-rw-r--r-- | core/config/project_settings.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/core/config/project_settings.cpp b/core/config/project_settings.cpp index 4638d70e59..ff5ff83bf8 100644 --- a/core/config/project_settings.cpp +++ b/core/config/project_settings.cpp @@ -360,8 +360,8 @@ void ProjectSettings::_get_property_list(List<PropertyInfo> *p_list) const { vclist.insert(vc); } - for (RBSet<_VCSort>::Element *E = vclist.front(); E; E = E->next()) { - String prop_info_name = E->get().name; + for (const _VCSort &E : vclist) { + String prop_info_name = E.name; int dot = prop_info_name.find("."); if (dot != -1 && !custom_prop_info.has(prop_info_name)) { prop_info_name = prop_info_name.substr(0, dot); @@ -369,11 +369,11 @@ void ProjectSettings::_get_property_list(List<PropertyInfo> *p_list) const { if (custom_prop_info.has(prop_info_name)) { PropertyInfo pi = custom_prop_info[prop_info_name]; - pi.name = E->get().name; - pi.usage = E->get().flags; + pi.name = E.name; + pi.usage = E.flags; p_list->push_back(pi); } else { - p_list->push_back(PropertyInfo(E->get().type, E->get().name, PROPERTY_HINT_NONE, "", E->get().flags)); + p_list->push_back(PropertyInfo(E.type, E.name, PROPERTY_HINT_NONE, "", E.flags)); } } } @@ -959,9 +959,9 @@ Error ProjectSettings::save_custom(const String &p_path, const CustomMap &p_cust RBMap<String, List<String>> props; - for (RBSet<_VCSort>::Element *E = vclist.front(); E; E = E->next()) { - String category = E->get().name; - String name = E->get().name; + for (const _VCSort &E : vclist) { + String category = E.name; + String name = E.name; int div = category.find("/"); |