Skip to content

Commit 0d10ad2

Browse files
committed
Revert double-click to open node catalog from #2423 because it occurs even outside the graph
1 parent 855acf7 commit 0d10ad2

File tree

1 file changed

+0
-24
lines changed

1 file changed

+0
-24
lines changed

editor/src/messages/portfolio/document/node_graph/node_graph_message_handler.rs

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -302,30 +302,6 @@ impl<'a> MessageHandler<NodeGraphMessage, NodeGraphHandlerData<'a>> for NodeGrap
302302
return;
303303
}
304304

305-
let Some(network_metadata) = network_interface.network_metadata(selection_network_path) else {
306-
log::error!("Could not get network metadata in NodeGraphMessage::EnterNestedNetwork");
307-
return;
308-
};
309-
310-
let click = ipp.mouse.position;
311-
let node_graph_point = network_metadata.persistent_metadata.navigation_metadata.node_graph_to_viewport.inverse().transform_point2(click);
312-
313-
// Check if clicked on empty area (no node, no input/output connector)
314-
let clicked_id = network_interface.node_from_click(click, selection_network_path);
315-
let clicked_input = network_interface.input_connector_from_click(click, selection_network_path);
316-
let clicked_output = network_interface.output_connector_from_click(click, selection_network_path);
317-
318-
if clicked_id.is_none() && clicked_input.is_none() && clicked_output.is_none() && self.context_menu.is_none() {
319-
// Create a context menu with node creation options
320-
self.context_menu = Some(ContextMenuInformation {
321-
context_menu_coordinates: (node_graph_point.x as i32, node_graph_point.y as i32),
322-
context_menu_data: ContextMenuData::CreateNode { compatible_type: None },
323-
});
324-
325-
responses.add(FrontendMessage::UpdateContextMenuInformation {
326-
context_menu_information: self.context_menu.clone(),
327-
});
328-
}
329305
let Some(node_id) = network_interface.node_from_click(ipp.mouse.position, selection_network_path) else {
330306
return;
331307
};

0 commit comments

Comments
 (0)