Class RadListBoxDragDropHelper
Represents drag and drop helper for the RadListBox control.
Inheritance
Inherited Members
Namespace: Telerik.Windows.Controls
Assembly: Telerik.Windows.Controls.dll
Syntax
public class RadListBoxDragDropHelper : DragDropHelper<ListBoxDragDropBehavior, DragDropState>
Constructors
RadListBoxDragDropHelper()
Initializes a new instance of the Rad
Declaration
public RadListBoxDragDropHelper()
Methods
CreateStateForDrop(FrameworkElement, FrameworkElement, Object, Type)
Creates and initializes a DragDropState from the provided DragEventArgs.
Declaration
protected override DragDropState CreateStateForDrop(FrameworkElement dropTarget, FrameworkElement dropItemsControl, object data, Type itemType)
Parameters
System.
|
System.
|
System.
|
System.
|
Returns
Overrides
DragDropCompleted(FrameworkElement, Object, Type, Boolean)
When overridden in a derived class allows calling custom code on the DragDropCompleted event.
Declaration
protected override void DragDropCompleted(FrameworkElement dropItemsControl, object data, Type itemType, bool wasCanceled)
Parameters
System.
|
System.
|
System.
|
System.
|
Overrides
DragLeave(FrameworkElement, FrameworkElement, Object, Type)
Hides the drop visual on mouse leave.
Declaration
protected override void DragLeave(FrameworkElement dropTarget, FrameworkElement dropItemsControl, object data, Type itemType)
Parameters
System. The object that is being dropped. |
System. The destination ItemsControl. |
System. The drag and drop data. |
System. The data type of the dragged item. |
Overrides
DragOver(FrameworkElement, FrameworkElement, Object, Type)
When overridden in a derived class allows calling custom code on the DragOver event.
Declaration
protected override DragDropEffects DragOver(FrameworkElement dropTarget, FrameworkElement dropItemsControl, object data, Type itemType)
Parameters
System.
|
System.
|
System.
|
System.
|
Returns
System.
|
Overrides
Drop(FrameworkElement, FrameworkElement, Object, Type)
Drops the specified drop target.
Declaration
protected override void Drop(FrameworkElement dropTarget, FrameworkElement dropItemsControl, object data, Type itemType)
Parameters
System.
|
System.
|
System.
|
System.
|
Overrides
FindDraggedItem(FrameworkElement)
Finds the ListBoxItem that contains the provided element.
Declaration
protected override FrameworkElement FindDraggedItem(FrameworkElement element)
Parameters
System. The element that raised the DragInitialize event. |
Returns
System.
|
Overrides
FindDragSource(FrameworkElement)
Finds the ListBox that contains the provided element.
Declaration
protected override FrameworkElement FindDragSource(FrameworkElement element)
Parameters
System. The element that raised the DragInitialize event. |
Returns
System.
|
Overrides
FindDropItemsControl(FrameworkElement, Object)
Finds the ListBox that should accept the dragged items.
Declaration
protected override FrameworkElement FindDropItemsControl(FrameworkElement element, object data)
Parameters
System. The element that raised the Drop event. |
System. The DataObject for the current drag operation. |
Returns
System.
|
Overrides
FindDropTarget(FrameworkElement)
Finds a ListBoxItem from the target control that contains the provided element.
Declaration
protected override FrameworkElement FindDropTarget(FrameworkElement element)
Parameters
System. The element that raised the Drop event. |
Returns
System.
|
Overrides
GetDraggedItems(FrameworkElement)
Returns the SelectedItems list of the ListBox that contains the dragged item and adds the dragged item to the list if it is not already present there.
Declaration
protected override IEnumerable<object> GetDraggedItems(FrameworkElement draggedItem)
Parameters
System. The source control of the drag operation. |
Returns
System. The items that should be dragged. |
Overrides
SetDropVisualPlaceholder(ContentPresenter)
Initialize the DragVisualPlaceholder used in the DragAndDrop operations.
Declaration
public void SetDropVisualPlaceholder(ContentPresenter dropVisualPlaceholder)
Parameters
System.
|
SetDropVisualProvider(IDropVisualProvider)
Initialize the DropVisualProvider used in the DragAndDrop operations.
Declaration
public void SetDropVisualProvider(IDropVisualProvider dropVisualProvider)
Parameters
IDrop
|