Fix block group output & expand/collapse all

This commit is contained in:
azakhi
2018-09-06 14:31:06 +03:00
parent 4bed777427
commit 1ee38b4c0e
3 changed files with 18 additions and 10 deletions

View File

@@ -166,6 +166,15 @@ namespace Filtration.ViewModels
}
}
public void SetIsExpandedForAll(bool isExpanded)
{
IsExpanded = isExpanded;
foreach(var child in VisibleChildGroups)
{
child.SetIsExpandedForAll(isExpanded);
}
}
public void RecalculateCheckState()
{
_isShowChecked = DetermineCheckState(true);

View File

@@ -126,7 +126,7 @@ namespace Filtration.ViewModels.ToolPanes
{
foreach (var vm in BlockGroupViewModels)
{
vm.IsExpanded = true;
vm.SetIsExpandedForAll(true);
}
}
@@ -134,7 +134,7 @@ namespace Filtration.ViewModels.ToolPanes
{
foreach (var vm in BlockGroupViewModels)
{
vm.IsExpanded = false;
vm.SetIsExpandedForAll(false);
}
}
}