summaryrefslogtreecommitdiff
path: root/editor/editor_folding.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/editor_folding.cpp')
-rw-r--r--editor/editor_folding.cpp16
1 files changed, 10 insertions, 6 deletions
diff --git a/editor/editor_folding.cpp b/editor/editor_folding.cpp
index 9f98795e16..97a2c67c26 100644
--- a/editor/editor_folding.cpp
+++ b/editor/editor_folding.cpp
@@ -259,13 +259,17 @@ void EditorFolding::_do_object_unfolds(Object *p_object, Set<RES> &resources) {
}
}
}
- }
- if (E->get().type == Variant::OBJECT) {
- RES res = p_object->get(E->get().name);
- if (res.is_valid() && !resources.has(res) && res->get_path() != String() && !res->get_path().is_resource_file()) {
- resources.insert(res);
- _do_object_unfolds(res.ptr(), resources);
+ if (E->get().type == Variant::OBJECT) {
+ RES res = p_object->get(E->get().name);
+ print_line("res: " + String(E->get().name) + " valid " + itos(res.is_valid()));
+ if (res.is_valid()) {
+ print_line("path " + res->get_path());
+ }
+ if (res.is_valid() && !resources.has(res) && res->get_path() != String() && !res->get_path().is_resource_file()) {
+ resources.insert(res);
+ _do_object_unfolds(res.ptr(), resources);
+ }
}
}
}