Fix more errors in Visject context menu regressions

This commit is contained in:
Wojtek Figat
2025-10-15 14:44:58 +02:00
parent 09fa3ce4be
commit c635d93b3c

View File

@@ -462,7 +462,7 @@ namespace FlaxEditor.Surface.ContextMenu
Parent = group Parent = group
}; };
} }
if (_contextSensitiveSearchEnabled) if (_contextSensitiveSearchEnabled && _selectedBoxes.Count > 0)
group.EvaluateVisibilityWithBox(_selectedBoxes[0]); group.EvaluateVisibilityWithBox(_selectedBoxes[0]);
group.SortChildren(); group.SortChildren();
if (ShowExpanded) if (ShowExpanded)
@@ -476,7 +476,7 @@ namespace FlaxEditor.Surface.ContextMenu
if (!isLayoutLocked) if (!isLayoutLocked)
{ {
if (_contextSensitiveSearchEnabled && _selectedBoxes[0] != null) if (_contextSensitiveSearchEnabled && _selectedBoxes.Count != 0 && _selectedBoxes[0] != null)
UpdateFilters(); UpdateFilters();
else else
SortGroups(); SortGroups();