feat(ui): ゲーム一覧の仮想スクロール最適化(Recycling・Pixel単位スクロール)の実装
This commit is contained in:
1 parent
ae86b53147
commit
c03cc97af1
1 file changed
+7
-2
+7
-2
@@ -420,6 +420,11 @@
|
|||||||
<ListBox x:Name="lstGames" Background="Transparent" BorderThickness="0"
|
<ListBox x:Name="lstGames" Background="Transparent" BorderThickness="0"
|
||||||
ScrollViewer.HorizontalScrollBarVisibility="Disabled"
|
ScrollViewer.HorizontalScrollBarVisibility="Disabled"
|
||||||
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
ScrollViewer.VerticalScrollBarVisibility="Auto"
|
||||||
|
ScrollViewer.CanContentScroll="True"
|
||||||
|
VirtualizingPanel.IsVirtualizing="True"
|
||||||
|
VirtualizingPanel.VirtualizationMode="Recycling"
|
||||||
|
VirtualizingPanel.ScrollUnit="Pixel"
|
||||||
|
VirtualizingPanel.IsContainerVirtualizable="True"
|
||||||
SelectionChanged="lstGames_SelectionChanged"
|
SelectionChanged="lstGames_SelectionChanged"
|
||||||
MouseDoubleClick="lstGames_MouseDoubleClick"
|
MouseDoubleClick="lstGames_MouseDoubleClick"
|
||||||
Padding="12">
|
Padding="12">
|
||||||
@@ -495,7 +500,7 @@
|
|||||||
<Grid>
|
<Grid>
|
||||||
<TextBlock Text="🎮" FontSize="20" HorizontalAlignment="Center" VerticalAlignment="Center" Opacity="0.4"
|
<TextBlock Text="🎮" FontSize="20" HorizontalAlignment="Center" VerticalAlignment="Center" Opacity="0.4"
|
||||||
Visibility="{Binding IconImage, Converter={x:Static helpers:NullToVisibleConverter.Instance}}"/>
|
Visibility="{Binding IconImage, Converter={x:Static helpers:NullToVisibleConverter.Instance}}"/>
|
||||||
<Image Source="{Binding IconImage}" Width="36" Height="36" Stretch="Uniform" RenderOptions.BitmapScalingMode="HighQuality"/>
|
<Image Source="{Binding IconImage}" Width="36" Height="36" Stretch="Uniform" RenderOptions.BitmapScalingMode="LowQuality"/>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Border>
|
</Border>
|
||||||
|
|
||||||
@@ -729,7 +734,7 @@
|
|||||||
<TextBlock Text="🎮" FontSize="26" HorizontalAlignment="Center" VerticalAlignment="Center" Opacity="0.4"
|
<TextBlock Text="🎮" FontSize="26" HorizontalAlignment="Center" VerticalAlignment="Center" Opacity="0.4"
|
||||||
Visibility="{Binding SelectedItem.IconImage, ElementName=lstGames, Converter={x:Static helpers:NullToVisibleConverter.Instance}}"/>
|
Visibility="{Binding SelectedItem.IconImage, ElementName=lstGames, Converter={x:Static helpers:NullToVisibleConverter.Instance}}"/>
|
||||||
<Image Source="{Binding SelectedItem.IconImage, ElementName=lstGames}" Stretch="Uniform" Width="48" Height="48"
|
<Image Source="{Binding SelectedItem.IconImage, ElementName=lstGames}" Stretch="Uniform" Width="48" Height="48"
|
||||||
RenderOptions.BitmapScalingMode="HighQuality"/>
|
RenderOptions.BitmapScalingMode="LowQuality"/>
|
||||||
</Grid>
|
</Grid>
|
||||||
</Border>
|
</Border>
|
||||||
<StackPanel Grid.Column="1" VerticalAlignment="Center">
|
<StackPanel Grid.Column="1" VerticalAlignment="Center">
|
||||||
|
|||||||
Reference in new issue
Block a user