2014-03-30 23:56:14 -07:00
|
|
|
<UserControl x:Class="Stylet.Samples.RedditBrowser.Pages.PostCommentsView"
|
|
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
|
|
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:redditapi="clr-namespace:Stylet.Samples.RedditBrowser.RedditApi"
|
2014-04-23 09:47:42 -07:00
|
|
|
xmlns:s="https://github.com/canton7/Stylet"
|
2014-03-31 05:28:52 -07:00
|
|
|
xmlns:uc="clr-namespace:Stylet.Samples.RedditBrowser.UserControls"
|
2014-03-30 23:56:14 -07:00
|
|
|
mc:Ignorable="d"
|
|
|
|
d:DesignHeight="300" d:DesignWidth="300">
|
|
|
|
<DockPanel>
|
|
|
|
<Button DockPanel.Dock="Top" HorizontalAlignment="Left" Command="{s:Action GoBack}">Back</Button>
|
2014-03-31 05:28:52 -07:00
|
|
|
<uc:StretchingTreeView ItemsSource="{Binding CommentCollection.Comments}" ScrollViewer.HorizontalScrollBarVisibility="Disabled">
|
|
|
|
<uc:StretchingTreeView.Resources>
|
|
|
|
<Style TargetType="uc:StretchingTreeViewItem">
|
2014-03-30 23:56:14 -07:00
|
|
|
<Setter Property="ToggleButtonVerticalAlignment" Value="Top"/>
|
|
|
|
</Style>
|
|
|
|
<HierarchicalDataTemplate DataType="{x:Type redditapi:Comment}" ItemsSource="{Binding Replies}">
|
|
|
|
<StackPanel Orientation="Vertical">
|
|
|
|
<TextBlock Text="{Binding Author}" FontWeight="Bold"/>
|
|
|
|
<TextBlock Text="{Binding Body}" TextWrapping="Wrap"/>
|
|
|
|
</StackPanel>
|
|
|
|
</HierarchicalDataTemplate>
|
2014-03-31 05:28:52 -07:00
|
|
|
</uc:StretchingTreeView.Resources>
|
|
|
|
</uc:StretchingTreeView>
|
2014-03-30 23:56:14 -07:00
|
|
|
</DockPanel>
|
|
|
|
</UserControl>
|