Last active
October 4, 2015 21:12
-
-
Save SuperJMN/435ad32e7c558903492a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ListView ScrollViewer.HorizontalScrollBarVisibility="Auto" | |
ScrollViewer.HorizontalScrollMode="Enabled" | |
ScrollViewer.VerticalScrollMode="Disabled" | |
ItemsSource="{Binding Collection}"> | |
<ListView.ItemsPanel> | |
<ItemsPanelTemplate> | |
<StackPanel Background="Transparent" Orientation="Horizontal" /> | |
</ItemsPanelTemplate> | |
</ListView.ItemsPanel> | |
</ListView> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Style x:Key="ListViewItemStyle1" TargetType="ListViewItem"> | |
<Setter Property="FontFamily" Value="{ThemeResource ContentControlThemeFontFamily}"/> | |
<Setter Property="FontSize" Value="{ThemeResource ControlContentThemeFontSize}"/> | |
<Setter Property="Background" Value="Transparent"/> | |
<Setter Property="Foreground" Value="{ThemeResource SystemControlForegroundBaseHighBrush}"/> | |
<Setter Property="TabNavigation" Value="Local"/> | |
<Setter Property="IsHoldingEnabled" Value="True"/> | |
<Setter Property="Padding" Value="12,0,12,0"/> | |
<Setter Property="HorizontalContentAlignment" Value="Left"/> | |
<Setter Property="VerticalContentAlignment" Value="Center"/> | |
<Setter Property="MinWidth" Value="{ThemeResource ListViewItemMinWidth}"/> | |
<Setter Property="MinHeight" Value="{ThemeResource ListViewItemMinHeight}"/> | |
<Setter Property="Template"> | |
<Setter.Value> | |
<ControlTemplate TargetType="ListViewItem"> | |
<Border x:Name="border" Background="White" RenderTransformOrigin="0,0"> | |
<Border.RenderTransform> | |
<CompositeTransform/> | |
</Border.RenderTransform> | |
<VisualStateManager.VisualStateGroups> | |
<VisualStateGroup x:Name="CommonStates"> | |
<VisualStateGroup.Transitions> | |
<VisualTransition GeneratedDuration="0:0:0.1"/> | |
</VisualStateGroup.Transitions> | |
<VisualState x:Name="Normal"/> | |
<VisualState x:Name="Pressed"> | |
<Storyboard> | |
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleX)" Storyboard.TargetName="border"> | |
<EasingDoubleKeyFrame KeyTime="0" Value="1"/> | |
<EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="1.2"/> | |
</DoubleAnimationUsingKeyFrames> | |
<DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.RenderTransform).(CompositeTransform.ScaleY)" Storyboard.TargetName="border"> | |
<EasingDoubleKeyFrame KeyTime="0" Value="1"/> | |
<EasingDoubleKeyFrame KeyTime="0:0:0.2" Value="1.2"/> | |
</DoubleAnimationUsingKeyFrames> | |
<PointAnimationUsingKeyFrames EnableDependentAnimation="True" Storyboard.TargetProperty="(UIElement.RenderTransformOrigin)" Storyboard.TargetName="border"> | |
<EasingPointKeyFrame KeyTime="0" Value="0,0"/> | |
<EasingPointKeyFrame KeyTime="0:0:0.2" Value="0,0"/> | |
</PointAnimationUsingKeyFrames> | |
</Storyboard> | |
</VisualState> | |
<VisualState x:Name="PointerOverPressed"/> | |
<VisualState x:Name="Disabled"/> | |
</VisualStateGroup> | |
</VisualStateManager.VisualStateGroups> | |
<ContentPresenter /> | |
</Border> | |
</ControlTemplate> | |
</Setter.Value> | |
</Setter> | |
</Style> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment