Display Select All Private checkbox in Send tab only
MODIFY
WalletWasabi.Gui/Controls/WalletExplorer/CoinJoinTabView.xaml
WalletWasabi.Gui/Controls/WalletExplorer/CoinJoinTabView.xaml
<Setter Property="Padding" Value="0 0 5 0" />
</Style>
</Grid.Styles>
- <local:CoinListView DataContext="{Binding CoinsList}" />
+ <local:CoinListView SelectAllPrivateVisible="False" DataContext="{Binding CoinsList}" />
</Grid>
<Grid Grid.Row="1">
<Grid.RowDefinitions>

MODIFY
WalletWasabi.Gui/Controls/WalletExplorer/CoinListView.xaml
WalletWasabi.Gui/Controls/WalletExplorer/CoinListView.xaml
</Grid>
<StackPanel Margin="0 10 0 0" Spacing="10" DockPanel.Dock="Bottom" Orientation="Horizontal">
<CheckBox Content="Select All" IsThreeState="True" IsChecked="{Binding SelectAllCheckBoxState}" Command="{Binding SelectAllCheckBoxCommand}" />
- <CheckBox Content="Select All Private" IsThreeState="True" IsChecked="{Binding SelectPrivateCheckBoxState}" Command="{Binding SelectPrivateCheckBoxCommand}" ToolTip.Tip="Coins that have acquired the privacy target." />
+ <CheckBox Content="Select All Private" IsThreeState="True" IsChecked="{Binding SelectPrivateCheckBoxState}" Command="{Binding SelectPrivateCheckBoxCommand}" IsVisible="{Binding SelectAllPrivateVisible}" ToolTip.Tip="Coins that have acquired the privacy target." />
<CheckBox Content="Select All Non-Private" IsThreeState="True" IsChecked="{Binding SelectNonPrivateCheckBoxState}" Command="{Binding SelectNonPrivateCheckBoxCommand}" IsVisible="{Binding SelectAllNonPrivateVisible}" ToolTip.Tip="Coins that have not acquired the privacy target." />
<StackPanel Spacing="10" DockPanel.Dock="Bottom" Orientation="Horizontal" IsVisible="{Binding IsAnyCoinSelected}">
<TextBlock Text="|" />

MODIFY
WalletWasabi.Gui/Controls/WalletExplorer/CoinListView.xaml.cs
WalletWasabi.Gui/Controls/WalletExplorer/CoinListView.xaml.cs
@@ -19,11 +19,21 @@ namespace WalletWasabi.Gui.Controls.WalletExplorer
set => SetValue(SelectAllNonPrivateVisibleProperty, value);
}
+ public static readonly StyledProperty<bool> SelectAllPrivateVisibleProperty =
+ AvaloniaProperty.Register<CoinListView, bool>(nameof(SelectAllPrivateVisible), defaultBindingMode: BindingMode.OneWayToSource);
+
+ public bool SelectAllPrivateVisible
+ {
+ get => GetValue(SelectAllPrivateVisibleProperty);
+ set => SetValue(SelectAllPrivateVisibleProperty, value);
+ }
+
public CoinListView()
{
InitializeComponent();
SelectAllNonPrivateVisible = true;
+ SelectAllPrivateVisible = true;
this.WhenAnyValue(x => x.DataContext)
.Subscribe(dataContext =>
@@ -32,6 +42,8 @@ namespace WalletWasabi.Gui.Controls.WalletExplorer
{
// Value is only propagated when DataContext is set at the beginning.
viewmodel.SelectAllNonPrivateVisible = SelectAllNonPrivateVisible;
+
+ viewmodel.SelectAllPrivateVisible = SelectAllPrivateVisible;
}
});
}

MODIFY
WalletWasabi.Gui/Controls/WalletExplorer/CoinListViewModel.cs
WalletWasabi.Gui/Controls/WalletExplorer/CoinListViewModel.cs
@@ -42,6 +42,7 @@ namespace WalletWasabi.Gui.Controls.WalletExplorer
private bool _isAnyCoinSelected;
private bool _labelExposeCommonOwnershipWarning;
private bool _selectAllNonPrivateVisible;
+ private bool _selectAllPrivateVisible;
public Global Global { get; }
public CoinListContainerType CoinListContainerType { get; }
@@ -178,6 +179,12 @@ namespace WalletWasabi.Gui.Controls.WalletExplorer
set => this.RaiseAndSetIfChanged(ref _selectAllNonPrivateVisible, value);
}
+ public bool SelectAllPrivateVisible
+ {
+ get => _selectAllPrivateVisible;
+ set => this.RaiseAndSetIfChanged(ref _selectAllPrivateVisible, value);
+ }
+
private bool? GetCheckBoxesSelectedState(Func<CoinViewModel, bool> coinFilterPredicate)
{
var coins = Coins.Where(coinFilterPredicate).ToArray();

Display Select All Private checkbox in Send tab only