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

Drag and Drop within ListBox - no indicator when dropping into last position?

5 Answers 200 Views
DragAndDrop
This is a migrated thread and some comments may be shown as answers.
Steve
Top achievements
Rank 1
Steve asked on 27 Aug 2013, 03:27 PM
I am trying to get drag and drop within a list box working.  With the following XAML, I don't see the drop indicator when attempting to drop the item below the last item, yet the drop still works...

<UserControl.Resources>
         
        <ListBoxDragReorderWpf:TemplateViewModel x:Key="TemplateViewModel"/>
         
        <DataTemplate x:Key="RadListBoxItemTemplate">
            <TextBlock Text="{Binding Name}"/>
        </DataTemplate>
         
        <Style x:Key="RadListBoxContainerStyle" TargetType="{x:Type telerik:RadListBoxItem}">
            <Setter Property="telerik:DragDropManager.AllowCapturedDrag" Value="True"/>
        </Style>
         
        <Style x:Key="RadListBoxStyle"
               TargetType="{x:Type telerik:RadListBox}">
            <Setter Property="ItemContainerStyle" Value="{StaticResource RadListBoxContainerStyle}"/>
            <Setter Property="ItemTemplate" Value="{StaticResource RadListBoxItemTemplate}"/>
        </Style>
         
    </UserControl.Resources>
     
    <Grid DataContext="{StaticResource TemplateViewModel}">
         
        <telerik:RadListBox ItemsSource="{Binding Pages}"
                            Style="{StaticResource RadListBoxStyle}"
                            Width="100"
                            Height="200">
            <telerik:RadListBox.DragDropBehavior>
                <telerik:ListBoxDragDropBehavior/>
            </telerik:RadListBox.DragDropBehavior>
            <telerik:RadListBox.DragVisualProvider>
                <telerik:ScreenshotDragVisualProvider />
            </telerik:RadListBox.DragVisualProvider>
            <telerik:RadListBox.DropVisualProvider>
                <telerik:LinearDropVisualProvider />
            </telerik:RadListBox.DropVisualProvider>
        </telerik:RadListBox>     
         
    </Grid>

5 Answers, 1 is accepted

Sort by
0
Kalin
Telerik team
answered on 28 Aug 2013, 12:43 PM
Hello Steve,

We are aware of this behavior and it has already been logged in our public issue tracking system, you can track its status on the following link:
http://www.telerik.com/support/pits.aspx#/details/Issue=15320

Part of logged issue is the invisible horizontal line after the last item when dragging. When the ListBox is inside of a Grid it is completely invisible, but when it is inside of StackPanel the line is visible but may appear a little bit lower than should be. So as a work-around I would suggest that you put the ListBox inside StackPanel (I've tested that with the provided code and worked as expected).

Hope this will help you.

Regards,
Kalin
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
Ian
Top achievements
Rank 1
answered on 05 May 2014, 02:39 PM
Hi Kalin,

It seems that this issue still appears in 2014.1.331.45. Any update on this issue? I couldn't get any information from the public issue tracking system link above - it just goes to the main Support page.

Cheers,
Ian
0
Kalin
Telerik team
answered on 07 May 2014, 12:00 PM
Hi Ian,

This issue has been recently fixed. The fix is available with the latest internal build, so you can download it and test it.

Hope this helps.

Regards,
Kalin
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
0
Ian
Top achievements
Rank 1
answered on 07 May 2014, 03:34 PM
Thanks Kalin,

I will do. Any word on when the next official release will be available?

Cheers,
Ian
0
Kalin
Telerik team
answered on 08 May 2014, 07:20 AM
Hello Ian,

The next official release should be available at the end of June.

If you have any other questions let us know.

Regards,
Kalin
Telerik
 
Check out Telerik Analytics, the service which allows developers to discover app usage patterns, analyze user data, log exceptions, solve problems and profile application performance at run time. Watch the videos and start improving your app based on facts, not hunches.
 
Tags
DragAndDrop
Asked by
Steve
Top achievements
Rank 1
Answers by
Kalin
Telerik team
Ian
Top achievements
Rank 1
Share this question
or