<UserControl x:Class="Util.ManualDebug.StatusCell"
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
xmlns:local="clr-namespace:Util.ManualDebug"
|
xmlns:pu="https://opensource.panuon.com/wpf-ui"
|
mc:Ignorable="d" Padding="5" MaxHeight="80"
|
d:DesignHeight="450" d:DesignWidth="800">
|
<UserControl.Style>
|
<Style TargetType="UserControl">
|
<Style.Triggers>
|
<DataTrigger Binding="{Binding Status}" Value="{x:Static local:CellStatus.Closed}">
|
<Setter Property="Background" Value="Gray"/>
|
</DataTrigger>
|
<DataTrigger Binding="{Binding Status}" Value="{x:Static local:CellStatus.OK}">
|
<Setter Property="Background" Value="#2D8659"/>
|
<Setter Property="Foreground" Value="#FFF"/>
|
</DataTrigger>
|
<DataTrigger Binding="{Binding Status}" Value="{x:Static local:CellStatus.NG}">
|
<Setter Property="Background" Value="#C53030"/>
|
<Setter Property="Foreground" Value="#FFF"/>
|
</DataTrigger>
|
<DataTrigger Binding="{Binding Status}" Value="{x:Static local:CellStatus.Testing}">
|
<Setter Property="Background" Value="#3182CE"/>
|
<Setter Property="Foreground" Value="#FFF"/>
|
</DataTrigger>
|
</Style.Triggers>
|
</Style>
|
</UserControl.Style>
|
<Grid>
|
<Grid.RowDefinitions>
|
<RowDefinition/>
|
<RowDefinition/>
|
</Grid.RowDefinitions>
|
<TextBlock FontSize="20" FontWeight="Bold" Text="{Binding Title}"/>
|
<TextBlock Grid.Row="1" FontSize="18" Text="{Binding Status}"/>
|
</Grid>
|
</UserControl>
|