From db2470118e83ef3175fddd7ff58e51af7d83be25 Mon Sep 17 00:00:00 2001 From: Victor Chelaru Date: Tue, 30 Jan 2024 20:26:58 -0700 Subject: [PATCH] Fixed bug with selection changing. --- .../OfficialPlugins/TreeViewPlugin/Logic/SelectionLogic.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/FRBDK/Glue/OfficialPlugins/TreeViewPlugin/Logic/SelectionLogic.cs b/FRBDK/Glue/OfficialPlugins/TreeViewPlugin/Logic/SelectionLogic.cs index 3831bfac0..41c42ecb4 100644 --- a/FRBDK/Glue/OfficialPlugins/TreeViewPlugin/Logic/SelectionLogic.cs +++ b/FRBDK/Glue/OfficialPlugins/TreeViewPlugin/Logic/SelectionLogic.cs @@ -111,6 +111,11 @@ public static void HandleSelected(NodeViewModel nodeViewModel, bool focus, bool else { didSelectionChange = currentNodes.Any(item => item.Tag == nodeViewModel.Tag) == false; + + if(!didSelectionChange && replaceSelection) + { + didSelectionChange = currentNodes.Contains(nodeViewModel) == false; + } } @@ -119,6 +124,7 @@ public static void HandleSelected(NodeViewModel nodeViewModel, bool focus, bool currentNodes.Clear(); mainViewModel.DeselectResursively(callSelectionLogic: false); + }