Używam listbox i wrappanel do wyświetlania danych.Jak zawinąć ItemsPanel w LongListSelector?
Na przykład:
<ListBox ItemTemplate="{StaticResource ItemTemplateListBoxAnimation}">
<ListBox.ItemsPanel>
<ItemsPanelTemplate>
<toolkit:WrapPanel ItemHeight="150" ItemWidth="150">
</toolkit:WrapPanel>
</ItemsPanelTemplate>
</ListBox.ItemsPanel>
</ListBox>
<DataTemplate x:Key="ItemTemplateListBoxAnimation">
<Grid Width="130" Height="130">
<Image Source="{Binding Image}"/>
</Grid>
</DataTemplate>
To wyglądać następująco:
Teraz muszę korzystać LongListSelector i grupowanie wynik:
<toolkit:LongListSelector ItemTemplate="{StaticResource ItemTemplateListBoxAnimation}">
<toolkit:LongListSelector.GroupItemsPanel>
<ItemsPanelTemplate>
<toolkit:WrapPanel/>
</ItemsPanelTemplate>
</toolkit:LongListSelector.GroupItemsPanel>
</toolkit:LongListSelector>
Ale to wyglądać tak:
Muszę dostać:
Twoje założenia? Dziękuję
Doskonała odpowiedź! Chociaż dla mnie trochę hacky, więc na razie będę się trzymał ListBox. – MEMark