port from perforce

This commit is contained in:
2026-04-18 22:31:51 +02:00
commit 8d0ab5b7cc
8409 changed files with 3972376 additions and 0 deletions

View File

@@ -0,0 +1,78 @@
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" />
<Style x:Key="{x:Type ButtonBase}" TargetType="{x:Type ButtonBase}">
<Setter Property="SnapsToDevicePixels" Value="True" />
<Setter Property="Foreground" Value="{DynamicResource ForegroundGradient}" />
<Setter Property="FocusVisualStyle" Value="{x:Null}" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid Background="{DynamicResource PseudoTransparent}">
<Border x:Name="checkedBorder" CornerRadius="2" BorderBrush="{DynamicResource SunkenBorder}" BorderThickness="1" Background="{DynamicResource SunkenGradient}" Visibility="Collapsed" />
<Border x:Name="hoverBorder" CornerRadius="2" BorderBrush="{DynamicResource DimSeparatingBorder}" BorderThickness="1" Background="{DynamicResource LightGradient}" />
<ContentPresenter x:Name="contentPresenter" HorizontalAlignment="Center" VerticalAlignment="Center" Margin="{TemplateBinding Padding}" />
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="hoverBorder" Property="Background" Value="{DynamicResource BrightGradient}" />
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter TargetName="hoverBorder" Property="Background" Value="{DynamicResource NormalGradient}" />
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="contentPresenter" Property="Opacity" Value="0.5" />
</Trigger>
<Trigger Property="ToggleButton.IsChecked" Value="True">
<Setter TargetName="checkedBorder" Property="Visibility" Value="Visible" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
<Style.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter Property="Foreground" Value="{DynamicResource HighlightGradient}" />
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter Property="Foreground" Value="{DynamicResource ForegroundGradient}" />
</Trigger>
</Style.Triggers>
</Style>
<Style x:Key="{x:Type Button}" TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type ButtonBase}}" />
<Style x:Key="{x:Type TextBlock}" TargetType="{x:Type TextBlock}">
<Setter Property="Foreground" Value="{DynamicResource Foreground}" />
</Style>
<Style x:Key="ToolButton" TargetType="{x:Type ButtonBase}" BasedOn="{StaticResource {x:Type ButtonBase}}">
<Setter Property="Width" Value="20" />
<Setter Property="Height" Value="20" />
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="{x:Type ButtonBase}">
<Grid Background="{DynamicResource PseudoTransparent}">
<Border x:Name="checkedBorder" CornerRadius="2" BorderBrush="{DynamicResource SunkenBorder}" BorderThickness="1" Background="{DynamicResource SunkenGradient}" Visibility="Collapsed" />
<Border x:Name="hoverBorder" CornerRadius="2" BorderBrush="{DynamicResource DimSeparatingBorder}" BorderThickness="1" Background="{DynamicResource BrightGradient}" Visibility="Collapsed" />
<ContentPresenter x:Name="contentPresenter" HorizontalAlignment="Center" VerticalAlignment="Center" />
</Grid>
<ControlTemplate.Triggers>
<Trigger Property="IsMouseOver" Value="True">
<Setter TargetName="hoverBorder" Property="Visibility" Value="Visible" />
</Trigger>
<Trigger Property="IsPressed" Value="True">
<Setter TargetName="hoverBorder" Property="Background" Value="{DynamicResource NormalGradient}" />
</Trigger>
<Trigger Property="IsEnabled" Value="False">
<Setter TargetName="contentPresenter" Property="Opacity" Value="0.5" />
</Trigger>
<Trigger Property="ToggleButton.IsChecked" Value="True">
<Setter TargetName="checkedBorder" Property="Visibility" Value="Visible" />
</Trigger>
</ControlTemplate.Triggers>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
</ResourceDictionary>