summaryrefslogtreecommitdiff
path: root/editor/plugins/theme_editor_plugin.cpp
diff options
context:
space:
mode:
authortrollodel <33117082+trollodel@users.noreply.github.com>2021-03-07 21:07:30 +0100
committertrollodel <33117082+trollodel@users.noreply.github.com>2021-05-17 22:06:46 +0200
commitbca0d36fe662477eb787b4ddc9b0b69ab4603393 (patch)
treeecf4ceaffa5559cb7a0fd0920997bad9a779532e /editor/plugins/theme_editor_plugin.cpp
parent92c04fa727e3fc507e31c1bce88beeceb98fb06a (diff)
Improve TreeItem API and allow to move nodes
Diffstat (limited to 'editor/plugins/theme_editor_plugin.cpp')
-rw-r--r--editor/plugins/theme_editor_plugin.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/editor/plugins/theme_editor_plugin.cpp b/editor/plugins/theme_editor_plugin.cpp
index 0f7468bead..f1c73f99dc 100644
--- a/editor/plugins/theme_editor_plugin.cpp
+++ b/editor/plugins/theme_editor_plugin.cpp
@@ -321,7 +321,7 @@ void ThemeItemImportTree::_toggle_type_items(bool p_collapse) {
return;
}
- TreeItem *type_node = root->get_children();
+ TreeItem *type_node = root->get_first_child();
while (type_node) {
type_node->set_collapsed(p_collapse);
type_node = type_node->get_next();
@@ -491,7 +491,7 @@ void ThemeItemImportTree::_tree_item_edited() {
}
void ThemeItemImportTree::_select_all_subitems(TreeItem *p_root_item, bool p_select_with_data) {
- TreeItem *child_item = p_root_item->get_children();
+ TreeItem *child_item = p_root_item->get_first_child();
while (child_item) {
child_item->set_checked(IMPORT_ITEM, true);
if (p_select_with_data) {
@@ -505,7 +505,7 @@ void ThemeItemImportTree::_select_all_subitems(TreeItem *p_root_item, bool p_sel
}
void ThemeItemImportTree::_deselect_all_subitems(TreeItem *p_root_item, bool p_deselect_completely) {
- TreeItem *child_item = p_root_item->get_children();
+ TreeItem *child_item = p_root_item->get_first_child();
while (child_item) {
child_item->set_checked(IMPORT_ITEM_DATA, false);
if (p_deselect_completely) {
@@ -527,7 +527,7 @@ void ThemeItemImportTree::_update_parent_items(TreeItem *p_root_item) {
bool any_checked = false;
bool any_checked_with_data = false;
- TreeItem *child_item = parent_item->get_children();
+ TreeItem *child_item = parent_item->get_first_child();
while (child_item) {
if (child_item->is_checked(IMPORT_ITEM)) {
any_checked = true;