Fix leaked signal connection to connection_layer.
This commit is contained in:
parent
91eb688e17
commit
04705d2899
1 changed files with 4 additions and 0 deletions
|
@ -695,6 +695,10 @@ void GraphEdit::remove_child_notify(Node *p_child) {
|
||||||
graph_element->disconnect("raise_request", callable_mp(this, &GraphEdit::_ensure_node_order_from));
|
graph_element->disconnect("raise_request", callable_mp(this, &GraphEdit::_ensure_node_order_from));
|
||||||
graph_element->disconnect("resize_request", callable_mp(this, &GraphEdit::_graph_element_resize_request));
|
graph_element->disconnect("resize_request", callable_mp(this, &GraphEdit::_graph_element_resize_request));
|
||||||
|
|
||||||
|
if (connections_layer != nullptr && connections_layer->is_inside_tree()) {
|
||||||
|
graph_element->disconnect(SceneStringName(item_rect_changed), callable_mp((CanvasItem *)connections_layer, &CanvasItem::queue_redraw));
|
||||||
|
}
|
||||||
|
|
||||||
// In case of the whole GraphEdit being destroyed these references can already be freed.
|
// In case of the whole GraphEdit being destroyed these references can already be freed.
|
||||||
if (minimap != nullptr && minimap->is_inside_tree()) {
|
if (minimap != nullptr && minimap->is_inside_tree()) {
|
||||||
graph_element->disconnect(SceneStringName(item_rect_changed), callable_mp((CanvasItem *)minimap, &GraphEditMinimap::queue_redraw));
|
graph_element->disconnect(SceneStringName(item_rect_changed), callable_mp((CanvasItem *)minimap, &GraphEditMinimap::queue_redraw));
|
||||||
|
|
Loading…
Reference in a new issue