allow user to adjust selected pockets.
MODIFY
WalletWasabi.Fluent/ViewModels/Wallets/Send/TransactionPreviewViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Send/TransactionPreviewViewModel.cs
@@ -34,6 +34,7 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
[AutoNotify] private SmartLabel _labels;
[AutoNotify] private string _amountText = "";
[AutoNotify] private bool _transactionHasChange;
+ [AutoNotify] private bool _transactionHasPockets;
public TransactionPreviewViewModel(Wallet wallet, TransactionInfo info)
{
@@ -98,6 +99,24 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
UpdateTransaction(optimisePrivacyDialog.Result);
}
});
+
+ ChangePocketsCommand = ReactiveCommand.CreateFromTask(async () =>
+ {
+ var selectPocketsDialog =
+ await NavigateDialogAsync(new PrivacyControlViewModel(wallet, info, false));
+
+ if (selectPocketsDialog.Kind == DialogResultKind.Normal && selectPocketsDialog.Result is { })
+ {
+ _info.Coins = selectPocketsDialog.Result;
+
+ var newTransaction = await BuildTransactionAsync();
+
+ if (newTransaction is { })
+ {
+ UpdateTransaction(newTransaction);
+ }
+ }
+ });
}
public bool PreferPsbtWorkflow => _wallet.KeyManager.PreferPsbtWorkflow;
@@ -112,6 +131,8 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
public ICommand AvoidChangeCommand { get; }
+ public ICommand ChangePocketsCommand { get; }
+
private async Task<bool> InitialiseTransactionAsync()
{
var transactionInfo = _info;
@@ -256,6 +277,8 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
FeeText = $"{btcFeeText}{fiatFeeText}";
TransactionHasChange = _transaction.OuterWalletOutputs.Sum(x => x.Amount) > fee && _transaction.InnerWalletOutputs.Sum(x => x.Amount) > 0;
+
+ TransactionHasPockets = !_info.IsPrivatePocketUsed;
}
protected override void OnNavigatedTo(bool isInHistory, CompositeDisposable disposables)

MODIFY
WalletWasabi.Fluent/Views/Wallets/Send/TransactionPreviewView.axaml
WalletWasabi.Fluent/Views/Wallets/Send/TransactionPreviewView.axaml
<Separator />
<c:PreviewItem Icon="{StaticResource entities_regular}"
Text="Will be sent to and / or known by">
+ <StackPanel Spacing="10">
<c:TagsBox Padding="0" IsReadOnly="True" Items="{Binding Labels}">
<c:TagsBox.Styles>
<Style Selector="c|TagsBox:readonly WrapPanel">
</Style>
</c:TagsBox.Styles>
</c:TagsBox>
+ <Button Classes="activeHyperLink" Content="Change who could know about this transaction." HorizontalAlignment="Left" Command="{Binding ChangePocketsCommand}" IsVisible="{Binding TransactionHasPockets}"/>
+ </StackPanel>
</c:PreviewItem>
<Separator />
<c:PreviewItem Icon="{StaticResource transceive_regular}"

allow user to adjust selected pockets.