Fix bug in cursor_in_finder computation

This commit is contained in:
Setzer22 2022-11-15 19:06:33 +01:00
parent 50b2ff94b2
commit 1f79e61a72

View File

@ -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;
}