DropPosition is always Inside - even when it's not really inside

6 posts, 0 answers
  1. Andrei Rinea
    Andrei Rinea avatar
    10 posts
    Member since:
    Jun 2008

    Posted 19 Jan 2011 Link to this post

    I have a small test project to check the Drag/Drop feature of RadTreeListView. Markup:

    <t:RadTreeListView ItemsSource="{Binding Items}" IsReadOnly="True" IsDragDropEnabled="True" x:Name="tree" AutoGenerateColumns="False">
    <t:RadTreeListView.DragCueItemTemplate>
    <DataTemplate>
    <StackPanel>
    <TextBlock Text="{Binding Name}"/>
    <StackPanel Orientation="Horizontal">
    <TextBlock Text="Children count : "/>
    <TextBlock Text="{Binding Children.Count}"/>
    </StackPanel>
    </StackPanel>
    </DataTemplate>
    </t:RadTreeListView.DragCueItemTemplate>
    <t:RadTreeListView.ChildTableDefinitions>
    <t:TreeListViewTableDefinition ItemsSource="{Binding Children}" />
    </t:RadTreeListView.ChildTableDefinitions>
    <t:RadTreeListView.Columns>
    <t:GridViewDataColumn DataMemberBinding="{Binding Name}" Header="Nume"/>
    </t:RadTreeListView.Columns>
    </t:RadTreeListView>

     

     

     

     


    Nothing fancy here... I bind it to a simple hierarchy of Node's and if I drag an item I receive this event in 

     

     

     

    private static void TreePreviewDragEnded(object sender, RadTreeListViewDragEndedEventArgs e)
    {
    Debug.WriteLine("DropPosition: " + e.DropPosition);
    Debug.WriteLine("IsCanceled: " + e.IsCanceled);
    Debug.WriteLine("TargetDropItem: " + (e.TargetDropItem == null ? "<null>" : e.TargetDropItem.ToString()));
    Debug.WriteLine("DraggedItems: " + e.DraggedItems);
    if (e.DraggedItems.Count > 0)
    {
    foreach (var item in e.DraggedItems)
    {
    Debug.WriteLine(" Dragged item : " + item);
    }
    }
    Debug.WriteLine("-----------------");
    }



    The issue is that no matter if I drop between (see attachment 1) or drop inside (see attachment 2) in the PreviewDragEnded event handler I always get e.DropPosition == Inside.

    Am I doing something wrong?

  2. Tsvyatko
    Admin
    Tsvyatko avatar
    833 posts

    Posted 25 Jan 2011 Link to this post

    Hello Andrei Rinea,

    We have have checked the described scenario and seems that there is issue regarding this functionality.

    I have logged this in our PITS system where you can track its progress - http://www.telerik.com/support/pits.aspx#/public/silverlight/4699

    I have also updated your telerik points.

    Kind regards,
    Tsvyatko
    the Telerik team
    Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
  3. UI for WPF is Visual Studio 2017 Ready
  4. Andrei Rinea
    Andrei Rinea avatar
    10 posts
    Member since:
    Jun 2008

    Posted 07 Feb 2011 Link to this post

    Thanks,

    However the platform I'm experiencing is WPF and not Silverlight. Maybe it's the same codebase but I don't know this for sure.

  5. Vlad
    Admin
    Vlad avatar
    11100 posts

    Posted 08 Feb 2011 Link to this post

    Hi,

     Indeed the issue is for both platforms. Here is the correct link for WPF:
    http://www.telerik.com/support/pits.aspx#/public/wpf/4699

    Regards,
    Vlad
    the Telerik team
    Let us know about your Windows Phone 7 application built with RadControls and we will help you promote it. Learn more>>
  6. John Slocum
    John Slocum avatar
    2 posts
    Member since:
    Apr 2009

    Posted 27 May 2014 Link to this post

    Hi,

    I'm currently having this same issue, but the links that were provided don't really show anything.
    I assume they used to be routed somewhere else.  Is there a new place one might find the answer to this question?

    Thanks

  7. Nick
    Admin
    Nick avatar
    593 posts

    Posted 28 May 2014 Link to this post

    Hello John,

    The issue was fixed recently, you can check our latest internal builds to see if the problem is solved with your scenario. 

    Regards,
    Nik
    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.
     
Back to Top
UI for WPF is Visual Studio 2017 Ready