Hello everyone,
We are having issues with vertical scroll when collapse/expand items in the TreeListView. Scroll starts to jump if we change style for GridViewCell:
XAML for TreeListView:
Please advice.
We are having issues with vertical scroll when collapse/expand items in the TreeListView. Scroll starts to jump if we change style for GridViewCell:
<Style x:Key="CellStyle" TargetType="telerik:GridViewCell"> <Setter Property="MinHeight" Value="50"/></Style>XAML for TreeListView:
<telerik:RadTreeListView x:Name="radTreeListView2" AutoGenerateColumns="False" Height="450" Width="400" BorderBrush="Black" BorderThickness="5" AutoExpandItems="True" ScrollViewer.HorizontalScrollBarVisibility="Visible" ScrollViewer.VerticalScrollBarVisibility="Visible"> <telerik:RadTreeListView.ChildTableDefinitions> <telerik:TreeListViewTableDefinition ItemsSource="{Binding Items}" /> </telerik:RadTreeListView.ChildTableDefinitions> <telerik:RadTreeListView.Columns> <telerik:GridViewDataColumn Header="Name" DataMemberBinding="{Binding Name}"/> <telerik:GridViewDataColumn Header="Count" DataMemberBinding="{Binding Count}"/> </telerik:RadTreeListView.Columns></telerik:RadTreeListView>
Steps to reproduce:
1. TreeListView should contain enough items, so scroll showed up
2. Scroll down to the middle or to the end
3.Collapse/Expand any item
AR: Scroll jumps to top (or to the middle)
ER: Scroll stays on the same place, so we can see collapsed/expanded item
Scroll is jumping even if we just put some content in CellTemplate:
<telerik:RadTreeListView.Columns> <telerik:GridViewDataColumn Header="Name" DataMemberBinding="{Binding Name}"/> <telerik:GridViewDataColumn Header="Count" DataMemberBinding="{Binding Count}"> <telerik:GridViewDataColumn.CellTemplate> <DataTemplate> <Border Height="50" Width="200" Background="LightGreen"/> </DataTemplate> </telerik:GridViewDataColumn.CellTemplate> </telerik:GridViewDataColumn></telerik:RadTreeListView.Columns>Please advice.