All the controls missing in WPF. Over 1 million downloads.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

59 lines
3.4 KiB

<infControls:DemoView x:Class="Samples.Modules.BusyIndicator.Views.BusyIndicatorView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:local="clr-namespace:Samples.Modules.BusyIndicator.Views"
xmlns:infControls="clr-namespace:Samples.Infrastructure.Controls;assembly=Samples.Infrastructure"
xmlns:extToolkit="http://schemas.microsoft.com/winfx/2006/xaml/presentation/toolkit/extended"
Title="BusyIndicator">
<infControls:DemoView.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="/Samples.Modules.Busyindicator;component/Resources/Common.xaml" />
</ResourceDictionary.MergedDictionaries>
<local:IntegerToTimespanConverter x:Key="TimeSpanConverter" />
</ResourceDictionary>
</infControls:DemoView.Resources>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<TextBlock Text="BusyIndicator makes it easy to let the user know when an application is busy. Simply wrap the relevant content in an instance of the BusyIndicator control and toggle its IsBusy property to True during any long-running process."
TextWrapping="Wrap" />
<GroupBox Header="Features" Grid.Row="1" Margin="5" >
<Grid Margin="5">
<Grid.RowDefinitions>
<RowDefinition Height="Auto" />
<RowDefinition Height="Auto" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" />
</Grid.ColumnDefinitions>
<TextBlock Text="IsBusy:" VerticalAlignment="Center" Margin="2"/>
<CheckBox x:Name="_isBusy" Grid.Column="1" IsChecked="True" VerticalAlignment="Center" Margin="5" ToolTip="When true shows the BusyIndicator" />
<TextBlock Text="DisplayAfter:" Grid.Row="1" VerticalAlignment="Center" Margin="2"/>
<StackPanel Grid.Row="1" Grid.Column="1" Margin="5" HorizontalAlignment="Left" Orientation="Horizontal">
<extToolkit:IntegerUpDown x:Name="_displayAfter" Width="65" VerticalAlignment="Center" Minimum="0" Increment="100" Value="0" ToolTip="Sets the TimeSpan to wait until the BusyIndicator is displayed." />
<TextBlock Text="milliseconds" Margin="5,0" VerticalAlignment="Center"/>
</StackPanel>
</Grid>
</GroupBox>
<StackPanel Grid.Row="2" Margin="10">
<TextBlock Text="Usage:" Style="{StaticResource Header}" />
<extToolkit:BusyIndicator IsBusy="{Binding IsChecked, ElementName=_isBusy}" DisplayAfter="{Binding Value, ElementName=_displayAfter, Converter={StaticResource TimeSpanConverter}}" >
<ContentControl ContentTemplate="{StaticResource SampleContent}" />
</extToolkit:BusyIndicator>
</StackPanel>
</Grid>
</infControls:DemoView>