Files
Semi.Avalonia/demo/Semi.Avalonia.Demo/Pages/ButtonSpinnerDemo.axaml

39 lines
1.5 KiB
XML

<UserControl
x:Class="Semi.Avalonia.Demo.Pages.ButtonSpinnerDemo"
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"
d:DesignHeight="450"
d:DesignWidth="800"
mc:Ignorable="d">
<StackPanel HorizontalAlignment="Left" Spacing="20">
<StackPanel Orientation="Horizontal">
<ToggleSwitch Name="showSpinCheck" IsChecked="True" Content="Show Button Spinner" />
<ToggleSwitch Name="allowSpinCheck" IsChecked="True" Content="Allow Spin" />
</StackPanel>
<ButtonSpinner
Height="30"
AllowSpin="{Binding #allowSpinCheck.IsChecked}"
BorderThickness="1"
ShowButtonSpinner="{Binding #showSpinCheck.IsChecked}"
Spin="OnSpin">
<TextBlock
HorizontalAlignment="Center"
VerticalAlignment="Center"
Text="A.S.I.A" />
</ButtonSpinner>
<ButtonSpinner
Height="30"
AllowSpin="{Binding #allowSpinCheck.IsChecked}"
BorderThickness="1"
ButtonSpinnerLocation="Left"
ShowButtonSpinner="{Binding #showSpinCheck.IsChecked}"
Spin="OnSpin">
<TextBlock
HorizontalAlignment="Center"
VerticalAlignment="Center"
Text="A.S.I.A" />
</ButtonSpinner>
</StackPanel>
</UserControl>