Browse Source

update default theme progress bar.

pull/4074/head
Dan Walmsley 6 years ago
parent
commit
1efda3744a
  1. 16
      src/Avalonia.Themes.Default/ProgressBar.xaml
  2. 2
      src/Avalonia.Themes.Fluent/ProgressBar.xaml

16
src/Avalonia.Themes.Default/ProgressBar.xaml

@ -1,4 +1,12 @@
<Styles xmlns="https://github.com/avaloniaui">
<Design.PreviewWith>
<Border Padding="20">
<StackPanel>
<ProgressBar VerticalAlignment="Center" IsIndeterminate="True" />
<ProgressBar HorizontalAlignment="Left" IsIndeterminate="True" Orientation="Vertical" />
</StackPanel>
</Border>
</Design.PreviewWith>
<Style Selector="ProgressBar">
<Setter Property="Background" Value="{DynamicResource ThemeAccentBrush4}"/>
<Setter Property="Foreground" Value="{DynamicResource ThemeAccentBrush}"/>
@ -53,11 +61,11 @@
Easing="LinearEasing">
<KeyFrame Cue="0%">
<Setter Property="TranslateTransform.X"
Value="{Binding IndeterminateStartingOffset, RelativeSource={RelativeSource TemplatedParent}}" />
Value="{Binding ContainerAnimationStartPosition, RelativeSource={RelativeSource TemplatedParent}}" />
</KeyFrame>
<KeyFrame Cue="100%">
<Setter Property="TranslateTransform.X"
Value="{Binding IndeterminateEndingOffset, RelativeSource={RelativeSource TemplatedParent}}" />
Value="{Binding ContainerAnimationEndPosition, RelativeSource={RelativeSource TemplatedParent}}" />
</KeyFrame>
</Animation>
</Style.Animations>
@ -69,11 +77,11 @@
Easing="LinearEasing">
<KeyFrame Cue="0%">
<Setter Property="TranslateTransform.Y"
Value="{Binding IndeterminateStartingOffset, RelativeSource={RelativeSource TemplatedParent}}" />
Value="{Binding ContainerAnimationStartPosition, RelativeSource={RelativeSource TemplatedParent}}" />
</KeyFrame>
<KeyFrame Cue="100%">
<Setter Property="TranslateTransform.Y"
Value="{Binding IndeterminateEndingOffset, RelativeSource={RelativeSource TemplatedParent}}" />
Value="{Binding ContainerAnimationEndPosition, RelativeSource={RelativeSource TemplatedParent}}" />
</KeyFrame>
</Animation>
</Style.Animations>

2
src/Avalonia.Themes.Fluent/ProgressBar.xaml

@ -2,7 +2,7 @@
<Design.PreviewWith>
<Border Padding="20">
<StackPanel>
<ProgressBar VerticalAlignment="Center" IsIndeterminate="True" Value="50" />
<ProgressBar VerticalAlignment="Center" IsIndeterminate="True" />
<ProgressBar HorizontalAlignment="Left" IsIndeterminate="True" Orientation="Vertical" />
</StackPanel>
</Border>

Loading…
Cancel
Save