Node: Rename child_exited_tree to child_exiting_tree

The name was confusing as this signal is emitted around the same time as
`tree_exiting` and `NOTIFICATION_EXIT_TREE`, i.e. while the child node is
still in tree.

Fixes #59210.

(cherry picked from commit 3e6de687b8)
This commit is contained in:
Rémi Verschelde
2022-06-20 09:53:44 +02:00
parent b8b7c21583
commit 0cb897421a
4 changed files with 12 additions and 6 deletions

View File

@@ -371,7 +371,7 @@ void Node::_propagate_exit_tree() {
if (data.parent) {
Variant c = this;
const Variant *cptr = &c;
data.parent->emit_signal(SceneStringNames::get_singleton()->child_exited_tree, &cptr, 1);
data.parent->emit_signal(SceneStringNames::get_singleton()->child_exiting_tree, &cptr, 1);
}
// exit groups
@@ -3149,7 +3149,7 @@ void Node::_bind_methods() {
ADD_SIGNAL(MethodInfo("tree_exiting"));
ADD_SIGNAL(MethodInfo("tree_exited"));
ADD_SIGNAL(MethodInfo("child_entered_tree", PropertyInfo(Variant::OBJECT, "node", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT, "Node")));
ADD_SIGNAL(MethodInfo("child_exited_tree", PropertyInfo(Variant::OBJECT, "node", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT, "Node")));
ADD_SIGNAL(MethodInfo("child_exiting_tree", PropertyInfo(Variant::OBJECT, "node", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT, "Node")));
ADD_PROPERTY(PropertyInfo(Variant::INT, "pause_mode", PROPERTY_HINT_ENUM, "Inherit,Stop,Process"), "set_pause_mode", "get_pause_mode");