add ReceiveWalletActionView.axaml
MODIFY
WalletWasabi.Fluent/ViewModels/WalletManagerViewModel.cs
WalletWasabi.Fluent/ViewModels/WalletManagerViewModel.cs
@@ -15,6 +15,7 @@ using WalletWasabi.Gui;
using WalletWasabi.Gui.ViewModels;
using WalletWasabi.Stores;
using WalletWasabi.Wallets;
+using ReceiveWalletActionViewModel = WalletWasabi.Fluent.ViewModels.Wallets.Receive.ReceiveWalletActionViewModel;
namespace WalletWasabi.Fluent.ViewModels
{

RENAME
WalletWasabi.Fluent/ViewModels/Wallets/Actions/ReceiveWalletActionViewModel.cs
WalletWasabi.Fluent/ViewModels/Wallets/Receive/ReceiveWalletActionViewModel.cs
@@ -7,11 +7,10 @@ using ReactiveUI;
using WalletWasabi.Blockchain.Analysis.Clustering;
using WalletWasabi.Blockchain.Keys;
using WalletWasabi.Fluent.ViewModels.NavBar;
-using WalletWasabi.Fluent.ViewModels.Wallets.Receive;
using WalletWasabi.Stores;
using WalletWasabi.Wallets;
-namespace WalletWasabi.Fluent.ViewModels.Wallets.Actions
+namespace WalletWasabi.Fluent.ViewModels.Wallets.Receive
{
[NavigationMetaData(
Title = "Receive",
@@ -34,7 +33,7 @@ namespace WalletWasabi.Fluent.ViewModels.Wallets.Actions
_suggestions = GetLabels(walletManager, bitcoinStore);
var nextCommandCanExecute =
- this.WhenAnyValue(x => x.Reference)
+ this.WhenAnyValue<ReceiveWalletActionViewModel, string>(x => x.Reference)
.ObserveOn(RxApp.MainThreadScheduler)
.Select(reference => !string.IsNullOrEmpty(reference));

MODIFY
WalletWasabi.Fluent/Views/Wallets/Actions/ReceiveWalletActionView.axaml
WalletWasabi.Fluent/Views/Wallets/Actions/ReceiveWalletActionView.axaml
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:c="using:WalletWasabi.Fluent.Controls"
xmlns:vm="using:WalletWasabi.Fluent.ViewModels.Wallets.Actions"
+ xmlns:receive="clr-namespace:WalletWasabi.Fluent.ViewModels.Wallets.Receive"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
- x:DataType="vm:ReceiveWalletActionViewModel"
+ x:DataType="receive:ReceiveWalletActionViewModel"
x:CompileBindings="True"
x:Class="WalletWasabi.Fluent.Views.Wallets.Actions.ReceiveWalletActionView">
<c:ContentArea Title="Receive" Caption=""

ADD
WalletWasabi.Fluent/Views/Wallets/Receive/ReceiveWalletActionView.axaml
+<UserControl xmlns="https://github.com/avaloniaui"
+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
+ xmlns:c="using:WalletWasabi.Fluent.Controls"
+ mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
+ xmlns:behaviors="using:WalletWasabi.Fluent.Behaviors"
+ xmlns:i="using:Avalonia.Xaml.Interactivity"
+ xmlns:receive="clr-namespace:WalletWasabi.Fluent.ViewModels.Wallets.Receive"
+ x:DataType="receive:ReceiveWalletActionViewModel"
+ x:CompileBindings="True"
+ x:Class="WalletWasabi.Fluent.Views.Wallets.Receive.ReceiveWalletActionView">
+ <c:ContentArea Title="{Binding Title}"
+ EnableNext="True" NextContent="Continue"
+ EnableCancel="True">
+ <DockPanel>
+ <StackPanel DockPanel.Dock="Top" HorizontalAlignment="Stretch">
+ <Label Content="_Reference" Target="ReferenceTbx" HorizontalAlignment="Left" FontWeight="Normal" />
+ <AutoCompleteBox Text="{Binding Reference}"
+ x:Name="ReferenceTbx"
+ Watermark='Who knows this address is yours? E.g.: "Max, BitPay"'
+ HorizontalAlignment="Stretch"
+ MinimumPrefixLength="1"
+ IsTextCompletionEnabled="True"
+ Items="{Binding Suggestions}">
+ <AutoCompleteBox.Styles>
+ <Style Selector="AutoCompleteBox /template/ Popup#PART_Popup">
+ <Setter Property="MaxWidth" Value="{Binding #ReferenceTbx.Bounds.Width}"/>
+ </Style>
+ </AutoCompleteBox.Styles>
+ <i:Interaction.Behaviors>
+ <behaviors:FocusOnAttachedBehavior IsEnabled="True"/>
+ </i:Interaction.Behaviors>
+ </AutoCompleteBox>
+ </StackPanel>
+
+ <Button Content="Previous unused addresses" Classes="h8 plain activeHyperLink" Command="{Binding ShowExistingAddressesCommand}" HorizontalAlignment="Center" VerticalAlignment="Bottom" DockPanel.Dock="Bottom"/>
+ </DockPanel>
+ </c:ContentArea>
+</UserControl>

ADD
WalletWasabi.Fluent/Views/Wallets/Receive/ReceiveWalletActionView.axaml.cs
+using Avalonia.Controls;
+using Avalonia.Markup.Xaml;
+
+namespace WalletWasabi.Fluent.Views.Wallets.Receive
+{
+ public class ReceiveWalletActionView : UserControl
+ {
+ public ReceiveWalletActionView()
+ {
+ InitializeComponent();
+ }
+
+ private void InitializeComponent()
+ {
+ AvaloniaXamlLoader.Load(this);
+ }
+ }
+}

MODIFY
WalletWasabi.Fluent/WalletWasabi.Fluent.csproj
WalletWasabi.Fluent/WalletWasabi.Fluent.csproj
<ProjectReference Include="..\WalletWasabi\WalletWasabi.csproj" />
<ProjectReference Include="..\WalletWasabi.Fluent.Generators\WalletWasabi.Fluent.Generators.csproj" OutputItemType="Analyzer" ReferenceOutputAssembly="false" />
</ItemGroup>
-
<ItemGroup>
<RuntimeHostConfigurationOption Include="System.Globalization.Invariant" Value="true" />
</ItemGroup>
-
- <ItemGroup>
- <Compile Update="Views\Login\PasswordFinder\PasswordNotFoundView.axaml.cs">
- <DependentUpon>PasswordNotFoundView.axaml</DependentUpon>
- <SubType>Code</SubType>
- </Compile>
- </ItemGroup>
</Project>

add ReceiveWalletActionView.axaml