Fix Visject surface select with Control to toggle selection of the node

This commit is contained in:
Wojtek Figat
2025-06-03 14:51:31 +02:00
parent 13b8863f0c
commit 6a0c734cec

View File

@@ -488,11 +488,9 @@ namespace FlaxEditor.Surface
// Check if user is pressing control // Check if user is pressing control
if (Root.GetKey(KeyboardKeys.Control)) if (Root.GetKey(KeyboardKeys.Control))
{ {
// Add to selection // Add/remove from selection
if (!controlUnderMouse.IsSelected) controlUnderMouse.IsSelected = !controlUnderMouse.IsSelected;
{ SelectionChanged?.Invoke();
AddToSelection(controlUnderMouse);
}
} }
// Check if node isn't selected // Check if node isn't selected
else if (!controlUnderMouse.IsSelected) else if (!controlUnderMouse.IsSelected)