Skip to content

Commit

Permalink
Merge branch 'General-Improvements'
Browse files Browse the repository at this point in the history
  • Loading branch information
Triky313 committed Dec 9, 2020
2 parents e053c95 + 372f671 commit 6fb4c93
Show file tree
Hide file tree
Showing 2 changed files with 73 additions and 25 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
namespace StatisticsAnalysisTool.IntegrationTests
{
[TestClass]
public class ApiController
public class ApiControllerTests
{
[TestMethod]
public void GetItemInfoFromJsonAsync_WithValidValues_ItemInformation()
Expand Down
96 changes: 72 additions & 24 deletions StatisticsAnalysisTool/StatisticsAnalysisTool/App.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,14 @@
<Color x:Key="Color.Text.ToOldSecond">#FF77778C</Color>
<Color x:Key="Color.Text.ToOldThird">#FF616172</Color>
<Color x:Key="Color.Text.NoValue">#FF4B4B59</Color>


<!-- Button colors -->
<Color x:Key="ControlNormalColor">#FF0e89b1</Color>
<Color x:Key="ControlMouseOverColor">#ff3da2ca</Color>
<Color x:Key="DisabledControlColor">#FF4B4B59</Color>
<Color x:Key="DisabledForegroundColor">#FFBFBFBF</Color>
<Color x:Key="ControlPressedColor">#ff57b6e0</Color>

<SolidColorBrush x:Key="SolidColorBrush.Foreground.First" Color="Gainsboro"/>
<SolidColorBrush x:Key="SolidColorBrush.Foreground.Second" Color="#B4B4B4"/>
<SolidColorBrush x:Key="SolidColorBrush.Background.First" Color="{StaticResource Background.First}" />
Expand Down Expand Up @@ -565,40 +572,81 @@
</Style.Triggers>
</Style>

<!-- Normal Button Style -->
<Style x:Key="ButtonStyle" TargetType="{x:Type Button}">
<Setter Property="BorderBrush">
<Style x:Key="ButtonFocusVisual">
<Setter Property="Control.Template">
<Setter.Value>
<SolidColorBrush Color="{StaticResource Color.Blue.3}"/>
<ControlTemplate>
<Border>
<Rectangle Margin="2" StrokeThickness="1" Stroke="#FF4B4B59" StrokeDashArray="1 2" />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>

<!-- Normal Button Style -->
<Style x:Key="ButtonStyle" TargetType="{x:Type Button}">
<Setter Property="SnapsToDevicePixels" Value="true" />
<Setter Property="OverridesDefaultStyle" Value="true" />
<Setter Property="FocusVisualStyle" Value="{StaticResource ButtonFocusVisual}" />
<Setter Property="MinHeight" Value="18px" />
<Setter Property="MinWidth" Value="40px" />
<Setter Property="Foreground" Value="{StaticResource SolidColorBrush.Foreground.First}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="Button">
<Border BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="1" CornerRadius="0">
<Border.Effect>
<DropShadowEffect Color="{StaticResource Color.Blue.3}" ShadowDepth="0"/>
</Border.Effect>
<TextBlock Foreground="{TemplateBinding BorderBrush}" Text="{TemplateBinding Content}"
HorizontalAlignment="Center" VerticalAlignment="Center"/>
<Border TextBlock.Foreground="{TemplateBinding Foreground}" x:Name="Border">
<Border.Background>
<SolidColorBrush Color="{DynamicResource ControlNormalColor}" />
</Border.Background>
<VisualStateManager.VisualStateGroups>
<VisualStateGroup x:Name="CommonStates">
<VisualStateGroup.Transitions>
<VisualTransition GeneratedDuration="0:0:0.1" />
<VisualTransition GeneratedDuration="0" To="Pressed" />
</VisualStateGroup.Transitions>
<VisualState x:Name="Normal" />
<VisualState x:Name="MouseOver">
<Storyboard>
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)"
Storyboard.TargetName="Border">
<EasingColorKeyFrame KeyTime="0" Value="{StaticResource ControlMouseOverColor}" />
</ColorAnimationUsingKeyFrames>
</Storyboard>
</VisualState>
<VisualState x:Name="Pressed">
<Storyboard>
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)"
Storyboard.TargetName="Border">
<EasingColorKeyFrame KeyTime="0" Value="{StaticResource ControlPressedColor}" />
</ColorAnimationUsingKeyFrames>
</Storyboard>
</VisualState>
<VisualState x:Name="Disabled">
<Storyboard>
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(Panel.Background).(SolidColorBrush.Color)"
Storyboard.TargetName="Border">
<EasingColorKeyFrame KeyTime="0" Value="{StaticResource DisabledControlColor}" />
</ColorAnimationUsingKeyFrames>
<ColorAnimationUsingKeyFrames Storyboard.TargetProperty="(TextBlock.Foreground).(SolidColorBrush.Color)"
Storyboard.TargetName="Border">
<EasingColorKeyFrame KeyTime="0" Value="{StaticResource DisabledForegroundColor}" />
</ColorAnimationUsingKeyFrames>
</Storyboard>
</VisualState>
</VisualStateGroup>
</VisualStateManager.VisualStateGroups>
<ContentPresenter Margin="2"
HorizontalAlignment="Center"
VerticalAlignment="Center"
RecognizesAccessKey="True" />
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="{StaticResource SolidColorBrush.Color.Button.First}" />
<Setter Property="Background" Value="{StaticResource SolidColorBrush.Color.Button.First}"/>
<Setter Property="BorderBrush" Value="{StaticResource SolidColorBrush.Color.Button.First}"/>
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter Property="Background" Value="{StaticResource SolidColorBrush.Color.Button.Second}" />
<Setter Property="BorderBrush" Value="{StaticResource SolidColorBrush.Color.Button.Second}"/>
</Trigger>
</Style.Triggers>
</Style>

<!-- Separator -->
<!-- Separator
<Style TargetType="Separator">
<Setter Property="Background">
<Setter.Value>
Expand All @@ -608,7 +656,7 @@
</RadialGradientBrush>
</Setter.Value>
</Setter>
</Style>
</Style> -->

<!-- PlayerMode label value last -->
<Style TargetType="Label" x:Key="PlayerMode.Label.Value.Last">
Expand Down

0 comments on commit 6fb4c93

Please sign in to comment.