From 1f79e61a72792651ada11eaad70416cfe7457365 Mon Sep 17 00:00:00 2001 From: Setzer22 Date: Tue, 15 Nov 2022 19:06:33 +0100 Subject: [PATCH] Fix bug in `cursor_in_finder` computation --- egui_node_graph/src/editor_ui.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/egui_node_graph/src/editor_ui.rs b/egui_node_graph/src/editor_ui.rs index 636614a..1f1fd26 100644 --- a/egui_node_graph/src/editor_ui.rs +++ b/egui_node_graph/src/editor_ui.rs @@ -196,9 +196,9 @@ where delayed_responses.push(NodeResponse::CreatedNode(new_node)); } let finder_rect = ui.max_rect(); - // If the cursor is not in the main editor, check if the cursor *is* in the finder + // If the cursor is not in the main editor, check if the cursor is in the finder // if the cursor is in the finder, then we can consider that also in the editor. - if !cursor_in_editor && finder_rect.contains(cursor_pos) { + if finder_rect.contains(cursor_pos) { cursor_in_editor = true; cursor_in_finder = true; }