diff options
Diffstat (limited to 'scene/main/resource_preloader.cpp')
-rw-r--r-- | scene/main/resource_preloader.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scene/main/resource_preloader.cpp b/scene/main/resource_preloader.cpp index cd9560db61..f4c90ee668 100644 --- a/scene/main/resource_preloader.cpp +++ b/scene/main/resource_preloader.cpp @@ -57,8 +57,8 @@ Array ResourcePreloader::_get_resources() const { Set<String> sorted_names; - for (Map<StringName, RES>::Element *E = resources.front(); E; E = E->next()) { - sorted_names.insert(E->key()); + for (const KeyValue<StringName, RES> &E : resources) { + sorted_names.insert(E.key); } int i = 0; @@ -131,8 +131,8 @@ Vector<String> ResourcePreloader::_get_resource_list() const { } void ResourcePreloader::get_resource_list(List<StringName> *p_list) { - for (Map<StringName, RES>::Element *E = resources.front(); E; E = E->next()) { - p_list->push_back(E->key()); + for (const KeyValue<StringName, RES> &E : resources) { + p_list->push_back(E.key); } } |