Hi telerik,
I'm trying to make the move from 'old school' d'n'd to the new based on latest release. I've tried to follow you example in documentation.
However, no events are activated. The dragged item is moved to new location, completely handled by the treeview (and none of my code discovers it).
Any suggestions on what to do?
Thanks,
Anders
xaml:
In the constructor of the usercontrol, holding the treeview:
None of them are implemented yet -- I'm expecting an exception:
I'm trying to make the move from 'old school' d'n'd to the new based on latest release. I've tried to follow you example in documentation.
However, no events are activated. The dragged item is moved to new location, completely handled by the treeview (and none of my code discovers it).
Any suggestions on what to do?
Thanks,
Anders
xaml:
<
Controls:RadTreeView
ItemsSource
=
"{Binding Path=WorkspaceViewModel.Children, NotifyOnSourceUpdated=True}"
Name
=
"treeview"
IsLineEnabled
=
"True"
MouseRightButtonDown
=
"TreeviewMouseRightButtonDown"
IsDragDropEnabled
=
"True"
SelectionMode
=
"Single"
MouseLeftButtonDown
=
"TreeviewMouseLeftButtonDown"
IsEditable
=
"{Binding CommandHandlerViewModel.CanEditSelected}"
ItemEditTemplate
=
"{StaticResource edittemplate}"
>
<
Controls:RadTreeView.Resources
>
<
Style
TargetType
=
"Controls:RadTreeView"
>
<
Setter
Property
=
"telerik:DragDropManager.AllowCapturedDrag"
Value
=
"True"
></
Setter
>
</
Style
>
</
Controls:RadTreeView.Resources
>
In the constructor of the usercontrol, holding the treeview:
DragDropManager.AddDragInitializeHandler(treeview, OnDragInitialize);
DragDropManager.AddGiveFeedbackHandler(treeview, OnGiveFeedback1);
DragDropManager.AddDragDropCompletedHandler(treeview, OnDragCompleted1);
DragDropManager.AddDropHandler(treeview, OnDrop1);
None of them are implemented yet -- I'm expecting an exception:
private
void
OnDragCompleted1(
object
sender, DragDropCompletedEventArgs e)
{
throw
new
NotImplementedException();
}
private
void
OnDrop1(
object
sender, Telerik.Windows.DragDrop.DragEventArgs e)
{
throw
new
NotImplementedException();
}
private
void
OnGiveFeedback1(
object
sender, GiveFeedbackEventArgs e)
{
throw
new
NotImplementedException();
}
private
void
OnDragInitialize(
object
sender, DragInitializeEventArgs e)
{
throw
new
NotImplementedException();
}