This is a migrated thread and some comments may be shown as answers.

Strange behaviour when both scrollbars visible and one scrollbar is dragged with mouse

2 Answers 29 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Anders
Top achievements
Rank 1
Anders asked on 26 Aug 2013, 10:58 AM
Hi telerik,

I tried to reproduce in your samples, but the size of window can't be reduced to show scrollbars.

But to reproduce, just insert 'sufficient' and 'wide enough' items. When both scrollbars are visible, drag scrollbar and the other scrollbar will move as well.

Yours,
Anders, Denmark

2 Answers, 1 is accepted

Sort by
0
Pavel R. Pavlov
Telerik team
answered on 29 Aug 2013, 06:40 AM
Hi Anders,

I tried to reproduce the reported behavior with our latest official release no our side and it seems the the code works as expected. Can you please take a look at the attached project and see if I missed something.

It will be great if you can change the code so that the issue can be reproduced in it and send it over. By doing so I will be able to further investigate the reasons behind the reported behavior.

Regards,
Pavel R. Pavlov
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
0
Anders
Top achievements
Rank 1
answered on 29 Aug 2013, 07:42 PM
It was indeed hard to reproduce! I tried moving code from our project and tried cutting off functinality in our project to remove the issue...

I finally struck gold and narrowed it down to a few lines in treeview xaml code that, when removed, also removed our problem...

I removed
<Style TargetType="Controls:RadTreeView">
    <Setter Property="telerik:DragDropManager.AllowCapturedDrag" Value="True"></Setter>
</Style>

From 
<Controls:RadTreeView.Resources>
    <HierarchicalDataTemplate DataType="{x:Type TreeViewItems:TreeViewItemViewModel}" ItemsSource="{Binding Children}" >
        <StackPanel Orientation="Horizontal" Margin="0" HorizontalAlignment="Left">
            <Image Width="16" Height="16" Margin="3,0" Source="{Binding VmImage}" />
            <TextBlock Text="{Binding DisplayName}" Margin="0" Padding="0" Style="{Binding TextStyle}"/>
        </StackPanel>
    </HierarchicalDataTemplate>
    <HierarchicalDataTemplate DataType="{x:Type TreeViewItems:ModelCollectionViewModel}"  >
        <StackPanel Orientation="Horizontal" Margin="0" >
            <Image Width="16" Height="16" Margin="3,0" Source="{Binding VmImage}" />
            <TextBlock Text="{Binding DisplayName}" Margin="0" Padding="0" Style="{Binding TextStyle}"/>
        </StackPanel>
    </HierarchicalDataTemplate>
    <Style TargetType="Controls:RadTreeView">
        <Setter Property="telerik:DragDropManager.AllowCapturedDrag" Value="True"></Setter>
    </Style>
</Controls:RadTreeView.Resources>

Apparently our drag and drop still works, so to us it smells like a solution!
Tags
TreeView
Asked by
Anders
Top achievements
Rank 1
Answers by
Pavel R. Pavlov
Telerik team
Anders
Top achievements
Rank 1
Share this question
or