reuse VirtualizingWrapPanel for display Dataset Explorer

This commit is contained in:
Alex Bezdieniezhnykh
2024-09-04 20:02:55 +03:00
parent 9436e96d81
commit b4bedb7520
7 changed files with 186 additions and 69 deletions
+18 -1
View File
@@ -3,9 +3,18 @@
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:vwp="clr-namespace:WpfToolkit.Controls;assembly=VirtualizingWrapPanel"
xmlns:local="clr-namespace:Azaion.Annotator"
xmlns:dto="clr-namespace:Azaion.Annotator.DTO"
mc:Ignorable="d"
Title="Браузер анотацій" Height="450" Width="800">
Title="Браузер анотацій" Height="900" Width="1200">
<Window.Resources>
<DataTemplate x:Key="ThumbnailTemplate" DataType="{x:Type dto:ThumbnailDto}">
<Image Source="{Binding Image}" Width="480" Height="270" Margin="5" />
</DataTemplate>
</Window.Resources>
<Grid
Name="MainGrid"
ShowGridLines="False"
@@ -22,5 +31,13 @@
<ColumnDefinition Width="4"/>
<ColumnDefinition Width="200" />
</Grid.ColumnDefinitions>
<vwp:GridView
Grid.Column="2"
Grid.Row="0"
Margin="2,5,2,2"
ItemsSource="{Binding ThumbnailsDtos, Mode=OneWay}"
ItemTemplate="{StaticResource ThumbnailTemplate}">
</vwp:GridView>
</Grid>
</Window>