Browse Source

Merge pull request #40128 from Chaosus/graphedit_reconnect_fix

Fix GraphEdit reconnecting to disconnected port
Yuri Roubinsky 5 years ago
parent
commit
17f5ebc4e8
1 changed files with 1 additions and 1 deletions
  1. 1 1
      scene/gui/graph_edit.cpp

+ 1 - 1
scene/gui/graph_edit.cpp

@@ -471,7 +471,7 @@ void GraphEdit::_top_layer_input(const Ref<InputEvent> &p_ev) {
 		connecting_to = mm->get_position();
 		connecting_target = false;
 		top_layer->update();
-		connecting_valid = click_pos.distance_to(connecting_to) > 20.0 * zoom;
+		connecting_valid = just_disconnected || click_pos.distance_to(connecting_to) > 20.0 * zoom;
 
 		if (connecting_valid) {
 			Ref<Texture2D> port = get_theme_icon("port", "GraphNode");