Class ListBoxDragDropTarget
A control that enables drag and drop operations on ListBox.
Inheritance
System.Object
ListBoxDragDropTarget
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: System.Windows.Controls
Assembly: OpenSilver.Controls.Toolkit.dll
Syntax
[TemplatePart(Name = "DragContainer", Type = typeof(Canvas))]
[TemplatePart(Name = "DragDecorator", Type = typeof(DragDecorator))]
[TemplatePart(Name = "InsertionIndicator", Type = typeof(Path))]
[TemplatePart(Name = "InsertionIndicatorContainer", Type = typeof(Canvas))]
[TemplatePart(Name = "DragPopup", Type = typeof(Popup))]
public class ListBoxDragDropTarget : ItemsControlDragDropTarget<ListBox, ListBoxItem>, IControl, IFrameworkElement, IUIElement, IDependencyObject, IAcceptDrop
Constructors
| Improve this Doc View SourceListBoxDragDropTarget()
Initializes a new instance of the ListBoxDragDropTarget class.
Declaration
public ListBoxDragDropTarget()
Properties
| Improve this Doc View SourceListBox
Gets the ListBox that is the drag drop target.
Declaration
protected ListBox ListBox { get; }
Property Value
Type | Description |
---|---|
ListBox |
Methods
| Improve this Doc View SourceOnContentChanged(Object, Object)
Ensures the content of control is a ListBox.
Declaration
protected override void OnContentChanged(object oldContent, object newContent)
Parameters
Type | Name | Description |
---|---|---|
System.Object | oldContent | The old content. |
System.Object | newContent | The new content. |
Overrides
| Improve this Doc View SourceOnItemDragStarting(ItemDragEventArgs)
Adds all selected items when drag operation begins.
Declaration
protected override void OnItemDragStarting(ItemDragEventArgs eventArgs)
Parameters
Type | Name | Description |
---|---|---|
ItemDragEventArgs | eventArgs | Information about the event. |
Overrides
System.Windows.Controls.DragDropTarget<System.Windows.Controls.ListBox, System.Windows.Controls.ListBoxItem>.OnItemDragStarting(System.Windows.Controls.ItemDragEventArgs)