1
0
Fork 0

Merge pull request #97809 from Geometror/fix-ge-conn-layer-warning

[GraphEdit] Only print warning for connection layer deletion when justified
This commit is contained in:
Rémi Verschelde 2024-10-04 22:43:49 +02:00
commit f6dbc04bd1
No known key found for this signature in database
GPG Key ID: C3336907360768E1
1 changed files with 3 additions and 1 deletions

View File

@ -653,7 +653,9 @@ void GraphEdit::remove_child_notify(Node *p_child) {
minimap = nullptr;
} else if (p_child == connections_layer) {
connections_layer = nullptr;
WARN_PRINT("GraphEdit's connection_layer removed. This should not be done. If you like to remove all GraphElements from a GraphEdit node, do not simply remove all non-internal children but check their type since the connection layer has to be kept non-internal due to technical reasons.");
if (is_inside_tree()) {
WARN_PRINT("GraphEdit's connection_layer removed. This should not be done. If you like to remove all GraphElements from a GraphEdit node, do not simply remove all non-internal children but check their type since the connection layer has to be kept non-internal due to technical reasons.");
}
}
if (top_layer != nullptr && is_inside_tree()) {