12345678910111213141516171819202122232425262728293031323334353637383940414243444546 |
- <ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
- <!-- 用于页面编辑的Item样式 -->
- <ControlTemplate x:Key="ListBoxItemControlTemplate" TargetType="{x:Type ListBoxItem}">
- <Border
- x:Name="Bd"
- Padding="{TemplateBinding Padding}"
- Background="{TemplateBinding Background}"
- BorderBrush="{TemplateBinding BorderBrush}"
- BorderThickness="{TemplateBinding BorderThickness}"
- SnapsToDevicePixels="True">
- <ContentPresenter
- Content="{TemplateBinding Content}"
- ContentStringFormat="{TemplateBinding ContentStringFormat}"
- ContentTemplate="{TemplateBinding ContentTemplate}"
- SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" />
- </Border>
- <ControlTemplate.Triggers>
- <!--<MultiTrigger>
- <MultiTrigger.Conditions>
- <Condition Property="IsMouseOver" Value="True" />
- </MultiTrigger.Conditions>
- <Setter TargetName="Bd" Property="Background" Value="#1A000000" />
- <Setter TargetName="Bd" Property="BorderBrush" Value="Transparent" />
- </MultiTrigger>
- <MultiTrigger>
- <MultiTrigger.Conditions>
- <Condition Property="Selector.IsSelectionActive" Value="False" />
- <Condition Property="IsSelected" Value="True" />
- </MultiTrigger.Conditions>
- --><!--<Setter TargetName="Bd" Property="Background" Value="#1A477EDE" />
- <Setter TargetName="Bd" Property="BorderBrush" Value="Transparent" />--><!--
- </MultiTrigger>
- <MultiTrigger>
- <MultiTrigger.Conditions>
- <Condition Property="Selector.IsSelectionActive" Value="True" />
- <Condition Property="IsSelected" Value="True" />
- </MultiTrigger.Conditions>
- --><!--<Setter TargetName="Bd" Property="Background" Value="#1A477EDE" />
- <Setter TargetName="Bd" Property="BorderBrush" Value="Transparent" />--><!--
- </MultiTrigger>
- <Trigger Property="IsEnabled" Value="False">
- <Setter TargetName="Bd" Property="TextElement.Foreground" Value="{DynamicResource {x:Static SystemColors.GrayTextBrushKey}}" />
- </Trigger>-->
- </ControlTemplate.Triggers>
- </ControlTemplate>
- </ResourceDictionary>
|