Add CommandParameter support
MODIFY
WalletWasabi.Fluent/Controls/AnimatedButton.axaml
WalletWasabi.Fluent/Controls/AnimatedButton.axaml
<Style Selector="c|AnimatedButton">
<Setter Property="Template">
<ControlTemplate>
- <Button Name="PART_Button" Command="{TemplateBinding Command}" Classes="plain">
+ <Button Name="PART_Button"
+ Command="{TemplateBinding Command}"
+ CommandParameter="{TemplateBinding CommandParameter}"
+ Classes="plain">
<i:Interaction.Behaviors>
<ia:EventTriggerBehavior EventName="Click">
<behaviors:AddClassAction StyledElement="{Binding #PART_IconNormal}" ClassName="hideAndShow" RemoveIfExists="True"/>

MODIFY
WalletWasabi.Fluent/Controls/AnimatedButton.axaml.cs
WalletWasabi.Fluent/Controls/AnimatedButton.axaml.cs
@@ -16,12 +16,21 @@ namespace WalletWasabi.Fluent.Controls
public static readonly StyledProperty<Geometry> ClickIconProperty =
AvaloniaProperty.Register<AnimatedButton, Geometry>(nameof(ClickIcon));
+ public static readonly StyledProperty<object> CommandParameterProperty =
+ AvaloniaProperty.Register<AnimatedButton, object>(nameof(CommandParameter));
+
public ICommand Command
{
get => GetValue(CommandProperty);
set => SetValue(CommandProperty, value);
}
+ public object CommandParameter
+ {
+ get => GetValue(CommandParameterProperty);
+ set => SetValue(CommandParameterProperty, value);
+ }
+
public Geometry NormalIcon
{
get => GetValue(NormalIconProperty);

Add CommandParameter support