make selection more obvious and show fiat amount
MODIFY
WalletWasabi.Fluent/Helpers/TransactionHelpers.cs
WalletWasabi.Fluent/Helpers/TransactionHelpers.cs
@@ -4,6 +4,7 @@ using NBitcoin;
using WalletWasabi.Blockchain.Analysis.Clustering;
using WalletWasabi.Blockchain.TransactionBuilding;
using WalletWasabi.Blockchain.TransactionOutputs;
+using WalletWasabi.Fluent.ViewModels.Wallets.Send;
using WalletWasabi.Wallets;
namespace WalletWasabi.Fluent.Helpers

MODIFY
WalletWasabi.Fluent/ViewModels/Wallets/Send/OptimisePrivacyViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Send/OptimisePrivacyViewModel.cs
@@ -84,12 +84,12 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
_privacySuggestions.Add(new PrivacySuggestionControlViewModel(
_transactionInfo.Amount.ToDecimal(MoneyUnit.BTC), smallerTransaction,
- PrivacyOptimisationLevel.Better, "Improved Privacy"));
+ PrivacyOptimisationLevel.Better, _wallet.Synchronizer.UsdExchangeRate, "Improved Privacy"));
}
_defaultSelection = new PrivacySuggestionControlViewModel(
_transactionInfo.Amount.ToDecimal(MoneyUnit.BTC), _requestedTransaction,
- PrivacyOptimisationLevel.Standard);
+ PrivacyOptimisationLevel.Standard, _wallet.Synchronizer.UsdExchangeRate);
_privacySuggestions.Add(_defaultSelection);
@@ -102,7 +102,7 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
_privacySuggestions.Add(new PrivacySuggestionControlViewModel(
_transactionInfo.Amount.ToDecimal(MoneyUnit.BTC), largerTransaction,
- PrivacyOptimisationLevel.Better, "Improved Privacy"));
+ PrivacyOptimisationLevel.Better, _wallet.Synchronizer.UsdExchangeRate, "Improved Privacy"));
SelectedPrivacySuggestion = _defaultSelection;

MODIFY
WalletWasabi.Fluent/ViewModels/Wallets/Send/PrivacySuggestionControlViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Send/PrivacySuggestionControlViewModel.cs
@@ -16,12 +16,13 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
public partial class PrivacySuggestionControlViewModel : ViewModelBase
{
private readonly BuildTransactionResult _transactionResult;
- [AutoNotify] private string _title;
+ [AutoNotify] private string _amount;
+ [AutoNotify] private string _amountFiat;
[AutoNotify] private string _caption;
[AutoNotify] private string[] _benefits;
[AutoNotify] private PrivacyOptimisationLevel _optimisationLevel;
- public PrivacySuggestionControlViewModel(decimal originalAmount, BuildTransactionResult transactionResult, PrivacyOptimisationLevel optimisationLevel, params string[] benefits)
+ public PrivacySuggestionControlViewModel(decimal originalAmount, BuildTransactionResult transactionResult, PrivacyOptimisationLevel optimisationLevel, decimal fiatExchangeRate, params string[] benefits)
{
_transactionResult = transactionResult;
_optimisationLevel = optimisationLevel;
@@ -40,7 +41,9 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Send
_caption = "As Requested";
}
- _title = $"{total}";
+ _amount = $"{total}";
+
+ _amountFiat = total.GenerateFiatText(fiatExchangeRate, "USD");
}
public BuildTransactionResult TransactionResult => _transactionResult;

MODIFY
WalletWasabi.Fluent/Views/Wallets/Send/OptimisePrivacyView.axaml
WalletWasabi.Fluent/Views/Wallets/Send/OptimisePrivacyView.axaml
<Setter Property="CornerRadius" Value="4" />
<Setter Property="Margin" Value="5" />
</Style>
- <Style Selector="ListBoxItem:selected /template/ ContentPresenter#PART_ContentPresenter">
- <Setter Property="Background" Value="{DynamicResource PrivacySuggestionControlSelectedBackground}" />
- </Style>
</ListBox.Styles>
<ListBox.ItemsPanel>
<ItemsPanelTemplate>

MODIFY
WalletWasabi.Fluent/Views/Wallets/Send/PrivacySuggestionControl.axaml
WalletWasabi.Fluent/Views/Wallets/Send/PrivacySuggestionControl.axaml
x:Class="WalletWasabi.Fluent.Views.Wallets.Send.PrivacySuggestionControl">
<StackPanel Spacing="20">
<Panel MinHeight="150" MinWidth="150">
- <StackPanel Spacing="10" VerticalAlignment="Top" TextBlock.Foreground="{Binding OptimisationLevel, Converter={x:Static conv:PrivacyOptimisationLevelConverters.OptimisationLevelToBrushConverter}}">
+ <StackPanel Spacing="10" VerticalAlignment="Top">
<Panel>
- <Ellipse Stroke="{Binding OptimisationLevel, Converter={x:Static conv:PrivacyOptimisationLevelConverters.OptimisationLevelToBrushConverter}, FallbackValue=White}" StrokeThickness="4" Height="115" Width="115" />
- <Ellipse Stroke="{Binding OptimisationLevel, Converter={x:Static conv:PrivacyOptimisationLevelConverters.OptimisationLevelToBrushConverter}, FallbackValue=White}" StrokeThickness="3" StrokeDashArray="2.0, 1.5" Height="100" Width="100" />
- <PathIcon Data="{StaticResource btc_logo}" Height="50" Width="50" Foreground="{Binding OptimisationLevel, Converter={x:Static conv:PrivacyOptimisationLevelConverters.OptimisationLevelToBrushConverter}, FallbackValue=White}" />
+ <Ellipse Stroke="{DynamicResource TextForegroundColor}" StrokeThickness="4" Height="115" Width="115" />
+ <Ellipse Stroke="{DynamicResource TextForegroundColor}" StrokeThickness="3" StrokeDashArray="2.0, 1.5" Height="100" Width="100" />
+ <PathIcon Data="{StaticResource btc_logo}" Height="50" Width="50" Foreground="{DynamicResource TextForegroundColor}" />
</Panel>
- <TextBlock Text="{Binding Title}" FontSize="20" HorizontalAlignment="Center" />
+ <TextBlock Text="{Binding Amount}" FontSize="20" HorizontalAlignment="Center" />
+ <TextBlock Text="{Binding AmountFiat}" HorizontalAlignment="Center" Opacity="0.6" />
<TextBlock Text="{Binding Caption}" HorizontalAlignment="Center" Opacity="0.6" />
</StackPanel>
</Panel>

make selection more obvious and show fiat amount