You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-06 12:20:30 +00:00
Improve TreeItem API and allow to move nodes
This commit is contained in:
@@ -59,7 +59,7 @@ void VisualScriptPropertySelector::_sbox_input(const Ref<InputEvent> &p_ie) {
|
||||
search_box->accept_event();
|
||||
|
||||
TreeItem *root = search_options->get_root();
|
||||
if (!root->get_children()) {
|
||||
if (!root->get_first_child()) {
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -265,7 +265,7 @@ void VisualScriptPropertySelector::_update_search() {
|
||||
item->set_metadata(2, connecting);
|
||||
}
|
||||
|
||||
if (category && category->get_children() == nullptr) {
|
||||
if (category && category->get_first_child() == nullptr) {
|
||||
memdelete(category); //old category was unused
|
||||
}
|
||||
}
|
||||
@@ -310,7 +310,7 @@ void VisualScriptPropertySelector::_update_search() {
|
||||
found = true;
|
||||
}
|
||||
|
||||
get_ok_button()->set_disabled(root->get_children() == nullptr);
|
||||
get_ok_button()->set_disabled(root->get_first_child() == nullptr);
|
||||
}
|
||||
|
||||
void VisualScriptPropertySelector::create_visualscript_item(const String &name, TreeItem *const root, const String &search_input, const String &text) {
|
||||
|
||||
Reference in New Issue
Block a user