Collapse/Expand all node in the tree if the user is pressing the Alt key.

This commit is contained in:
MineBill
2023-10-19 18:55:58 +03:00
parent 2f3685c161
commit c773c3e8fc

View File

@@ -776,11 +776,20 @@ namespace FlaxEditor.GUI.Tree
// Check if mouse hits arrow
if (_mouseOverArrow && HasAnyVisibleChild)
{
// Toggle open state
if (_opened)
Collapse();
if (ParentTree.Root.GetKey(KeyboardKeys.Alt))
{
if (_opened)
CollapseAll();
else
ExpandAll();
}
else
Expand();
{
if (_opened)
Collapse();
else
Expand();
}
}
// Check if mouse hits bar