diff options
Diffstat (limited to 'scene')
-rw-r--r-- | scene/gui/tree.cpp | 4 | ||||
-rw-r--r-- | scene/gui/tree.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/scene/gui/tree.cpp b/scene/gui/tree.cpp index ede7bfb0bf..52b45054a7 100644 --- a/scene/gui/tree.cpp +++ b/scene/gui/tree.cpp @@ -748,10 +748,10 @@ int TreeItem::get_child_count() { return children_cache.size(); } -Array TreeItem::get_children() { +TypedArray<TreeItem> TreeItem::get_children() { // Don't need to explicitly create children cache, because get_child_count creates it. int size = get_child_count(); - Array arr; + TypedArray<TreeItem> arr; arr.resize(size); for (int i = 0; i < size; i++) { arr[i] = children_cache[i]; diff --git a/scene/gui/tree.h b/scene/gui/tree.h index bcc2419b80..7f9c00b1b9 100644 --- a/scene/gui/tree.h +++ b/scene/gui/tree.h @@ -339,7 +339,7 @@ public: TreeItem *get_child(int p_idx); int get_visible_child_count(); int get_child_count(); - Array get_children(); + TypedArray<TreeItem> get_children(); int get_index(); #ifdef DEV_ENABLED |