summaryrefslogtreecommitdiffstats
path: root/scene/resources/theme.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/resources/theme.cpp')
-rw-r--r--scene/resources/theme.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/scene/resources/theme.cpp b/scene/resources/theme.cpp
index b6cd6f6dfe..1ac90b8980 100644
--- a/scene/resources/theme.cpp
+++ b/scene/resources/theme.cpp
@@ -1250,14 +1250,12 @@ void Theme::get_type_list(List<StringName> *p_list) const {
}
}
-void Theme::get_type_dependencies(const StringName &p_base_type, const StringName &p_type_variation, List<StringName> *p_list) {
- ERR_FAIL_NULL(p_list);
-
+void Theme::get_type_dependencies(const StringName &p_base_type, const StringName &p_type_variation, Vector<StringName> &r_result) {
// Build the dependency chain for type variations.
if (p_type_variation != StringName()) {
StringName variation_name = p_type_variation;
while (variation_name != StringName()) {
- p_list->push_back(variation_name);
+ r_result.push_back(variation_name);
variation_name = get_type_variation_base(variation_name);
// If we have reached the base type dependency, it's safe to stop (assuming no funny business was done to the Theme).
@@ -1268,7 +1266,7 @@ void Theme::get_type_dependencies(const StringName &p_base_type, const StringNam
}
// Continue building the chain using native class hierarchy.
- ThemeDB::get_singleton()->get_native_type_dependencies(p_base_type, p_list);
+ ThemeDB::get_singleton()->get_native_type_dependencies(p_base_type, r_result);
}
// Internal methods for getting lists as a Vector of String (compatible with public API).