csharpc-sharpdotnetxamlavaloniauicross-platformcross-platform-xamlavaloniaguimulti-platformuser-interfacedotnetcore
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
50 lines
2.2 KiB
50 lines
2.2 KiB
<Window xmlns="https://github.com/avaloniaui"
|
|
Title="AvaloniaUI Virtualization Test"
|
|
Width="800"
|
|
Height="600">
|
|
<Grid RowDefinitions="4*,3*,4*">
|
|
<ListBox Name="listBox"
|
|
Items="{Binding Items}"
|
|
SelectedItems="{Binding SelectedItems}"
|
|
ScrollViewer.HorizontalScrollBarVisibility="{Binding HorizontalScrollBarVisibility, Mode=TwoWay}"
|
|
ScrollViewer.VerticalScrollBarVisibility="{Binding VerticalScrollBarVisibility, Mode=TwoWay}">
|
|
<ListBox.ItemTemplate>
|
|
<DataTemplate>
|
|
<Grid>
|
|
<Expander ExpandDirection="Down">
|
|
<StackPanel Background="#FFFEFEFE">
|
|
<Panel Background="Red" Height="200" Width="200" />
|
|
</StackPanel>
|
|
</Expander>
|
|
<Grid ColumnDefinitions="400, *, 100" Margin="30 0 0 0">
|
|
<TextBlock Text="{Binding Header}" />
|
|
</Grid>
|
|
</Grid>
|
|
</DataTemplate>
|
|
</ListBox.ItemTemplate>
|
|
</ListBox>
|
|
|
|
<Grid Grid.Row="1" Background="LightBlue" />
|
|
|
|
<ListBox Name="listBox1" Grid.Row="2"
|
|
Items="{Binding Items2}"
|
|
ScrollViewer.HorizontalScrollBarVisibility="{Binding HorizontalScrollBarVisibility, Mode=TwoWay}"
|
|
ScrollViewer.VerticalScrollBarVisibility="{Binding VerticalScrollBarVisibility, Mode=TwoWay}">
|
|
<ListBox.ItemTemplate>
|
|
<DataTemplate>
|
|
<Grid>
|
|
<Expander ExpandDirection="Down">
|
|
<StackPanel Background="#FFFEFEFE">
|
|
<Panel Background="Red" Height="200" Width="200" />
|
|
</StackPanel>
|
|
</Expander>
|
|
<Grid ColumnDefinitions="400, *, 100" Margin="30 0 0 0">
|
|
<TextBlock Text="{Binding Header}" />
|
|
</Grid>
|
|
</Grid>
|
|
</DataTemplate>
|
|
</ListBox.ItemTemplate>
|
|
</ListBox>
|
|
|
|
</Grid>
|
|
</Window>
|
|
|