- Thread starter
- Admin
- #681
Audio languages are list of strings:
, so you should be able to use a ListView on that Property and define ContentTemplates for your needs (I've not tested it yet).
- public IEnumerable<string> AudioLanguages
Shouldn't it work like following. I tried it with a list of labels at first. However nothing is shown ...
HTML:
<media:VideoAspectWrapper MediaItem="{Binding MediaItem}" Grid.Column="1" Grid.Row="0" Grid.RowSpan="2" Margin="20,5,20,5">
<media:VideoAspectWrapper.Template>
<ControlTemplate>
<Grid Grid.Row="0" Grid.Column="0" DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"/>
</Grid.ColumnDefinitions>
<ListView Grid.Row="0" Grid.Column="0" x:Name="AudioLanguageList" ItemsSource="{Binding AudioLanguages}"
HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<ListView.ItemTemplate>
<DataTemplate>
<StackPanel Orientation="Horizontal">
<Label Content="{Binding}" />
</StackPanel>
</DataTemplate>
</ListView.ItemTemplate>
</ListView>
</Grid>
</ControlTemplate>
</media:VideoAspectWrapper.Template>
</media:VideoAspectWrapper>