Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <Window
- x:Class="LauncherBeta.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 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:local="clr-namespace:Launcher"
- Name="LauncherWindow"
- Title="Brickplanet Launcher"
- Height="256"
- Width="512"
- WindowStyle="None"
- ResizeMode="NoResize"
- WindowStartupLocation="CenterScreen" xmlns:launcherbeta="clr-namespace:LauncherBeta"
- ContentRendered="LauncherWindow_Rendered">
- <FrameworkElement.Resources>
- <ResourceDictionary>
- <SolidColorBrush
- Color="#FF06B025"
- x:Key="ProgressBar.Progress" />
- <SolidColorBrush
- Color="#FFE6E6E6"
- x:Key="ProgressBar.Background" />
- <SolidColorBrush
- Color="#FFBCBCBC"
- x:Key="ProgressBar.Border" />
- <Style
- TargetType="{x:Type ProgressBar}"
- x:Key="DownloadProgressBar">
- <Setter
- Property="Foreground"
- Value="{StaticResource ProgressBar.Progress}" />
- <Setter
- Property="Background"
- Value="{StaticResource ProgressBar.Background}" />
- <Setter
- Property="BorderBrush"
- Value="{StaticResource ProgressBar.Border}" />
- <Setter
- Property="BorderThickness"
- Value="1" />
- <Setter
- Property="Template">
- <Setter.Value>
- <ControlTemplate
- TargetType="{x:Type ProgressBar}">
- <Grid
- Name="TemplateRoot">
- <VisualStateManager.VisualStateGroups>
- <VisualStateGroup
- x:Name="CommonStates">
- <VisualState
- x:Name="Determinate" />
- <VisualState
- x:Name="Indeterminate">
- <Storyboard
- RepeatBehavior="Forever">
- <DoubleAnimationUsingKeyFrames
- Storyboard.TargetProperty="(UIElement.RenderTransform).(TransformGroup.Children)[0].(ScaleTransform.ScaleX)"
- Storyboard.TargetName="Animation">
- <EasingDoubleKeyFrame
- KeyTime="0"
- Value="0.25" />
- <EasingDoubleKeyFrame
- KeyTime="0:0:1"
- Value="0.25" />
- <EasingDoubleKeyFrame
- KeyTime="0:0:2"
- Value="0.25" />
- </DoubleAnimationUsingKeyFrames>
- <PointAnimationUsingKeyFrames
- Storyboard.TargetProperty="(UIElement.RenderTransformOrigin)"
- Storyboard.TargetName="Animation">
- <EasingPointKeyFrame
- KeyTime="0"
- Value="-0.5,0.5" />
- <EasingPointKeyFrame
- KeyTime="0:0:1"
- Value="0.5,0.5" />
- <EasingPointKeyFrame
- KeyTime="0:0:2"
- Value="1.5,0.5" />
- </PointAnimationUsingKeyFrames>
- </Storyboard>
- </VisualState>
- </VisualStateGroup>
- </VisualStateManager.VisualStateGroups>
- <Border
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}"
- Background="{TemplateBinding Background}"
- CornerRadius="5" />
- <Rectangle
- Name="PART_Track" />
- <Grid
- Name="PART_Indicator"
- ClipToBounds="True"
- HorizontalAlignment="Left">
- <Rectangle
- Name="Indicator"
- Fill="{TemplateBinding Foreground}"
- RadiusX="30"
- RadiusY="30" />
- <Rectangle
- Name="Animation"
- Fill="{TemplateBinding Foreground}"
- RenderTransformOrigin="0.5,0.5"
- RadiusX="5"
- RadiusY="5">
- <UIElement.RenderTransform>
- <TransformGroup>
- <ScaleTransform />
- <SkewTransform />
- <RotateTransform />
- <TranslateTransform />
- </TransformGroup>
- </UIElement.RenderTransform>
- </Rectangle>
- </Grid>
- </Grid>
- <ControlTemplate.Triggers>
- <Trigger
- Property="ProgressBar.Orientation"
- Value="Vertical">
- <Setter
- TargetName="TemplateRoot"
- Property="FrameworkElement.LayoutTransform">
- <Setter.Value>
- <RotateTransform
- Angle="-90" />
- </Setter.Value>
- </Setter>
- </Trigger>
- <Trigger
- Property="ProgressBar.IsIndeterminate"
- Value="True">
- <Setter
- TargetName="Indicator"
- Property="Visibility"
- Value="Collapsed" />
- </Trigger>
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </Setter.Value>
- </Setter>
- </Style>
- </ResourceDictionary>
- </FrameworkElement.Resources>
- <Grid
- Background="#FF272727">
- <Image
- Height="18"
- Margin="0,60,170,0"
- VerticalAlignment="Top"
- Source="Resources/bp-whit-logo6.png"
- HorizontalAlignment="Right"
- Width="175" />
- <TextBlock
- Name="updateText"
- TextWrapping="Wrap"
- TextAlignment="Center"
- Margin="81,164,0,0"
- RenderTransformOrigin="-0.526,-0.164"
- Foreground="#FFFFFFFF"
- Width="350"
- Height="92"
- HorizontalAlignment="Left"
- VerticalAlignment="Top"
- Background="{x:Null}" />
- <Grid
- Height="100" />
- <ProgressBar
- Name="downloadProgress"
- HorizontalAlignment="Left"
- Height="26"
- Margin="81,108,0,0"
- VerticalAlignment="Top"
- Width="350"
- Value="0"
- Background="#FF272727"
- BorderBrush="#FF323232"
- Style="{DynamicResource DownloadProgressBar}"
- Foreground="#FF1773AD" />
- </Grid>
- </Window>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement