'UWP TreeViewItem as WrapPanel
<DataTemplate x:Key="Group" x:DataType="model:GroupedTemplates">
<muxc:TreeViewItem ItemsSource="{Binding Projects}" >
<muxc:TreeViewItem.Content>
<TextBlock>
<Run Text="Pictures:"/>
<Run Text="{Binding CountOfPhotos}"/>
</TextBlock>
</muxc:TreeViewItem.Content>
</muxc:TreeViewItem>
</DataTemplate>
<DataTemplate x:Key="Template" x:DataType="model:Project">
<Button Command="{Binding ElementName=Page,
Path=DataContext.TemplateClickCommand}"
CommandParameter="{Binding}"
Content="{Binding PhotoArray,
Converter={StaticResource FromArrToGridConverter}}"/>
</DataTemplate>
<helpers:GroupTemplateSelector
x:Key="GroupTemplateSelector"
ProjectTemplate="{StaticResource Template}"
GroupTemplate="{StaticResource Group}"/>
<muxc:TreeView
ItemsSource="{Binding TemplateCollection}"
ItemTemplateSelector="{StaticResource GroupTemplateSelector}">
</muxc:TreeView>
As result, I have TreeView which items just go down like a list : https://i.stack.imgur.com/qZ77A.png
But I need that my elements in every TreeViewItem be in WrapPanel in Horizontal orientation. Could you help me?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
