Definition
Namespace:Telerik.WinControls.UI
Assembly:Telerik.WinControls.UI.dll
Syntax:
public class TreeViewDragDropService : RadDragDropService, IDisposable, INotifyPropertyChanged, ICustomTypeDescriptor, IMessageListener
Inheritance: objectDisposableObjectRadObjectRadServiceRadDragDropServiceTreeViewDragDropService...
Derived Classes:
Implements:
Inherited Members
Constructors
Properties
public Color DropHintColor { get; set; }
protected virtual bool IsCopyingNodes { get; }
protected RadTreeViewElement Owner { get; }
Gets or sets a value indicating whether drag hint should be shown.
public bool ShowDragHint { get; set; }
true if [show drag hint]; otherwise, false.
Gets or sets a value indicating whether show drop hint should be shown.
public bool ShowDropHint { get; set; }
true if [show drop hint]; otherwise, false.
Methods
protected virtual bool CancelPreviewDragDrop(RadDropEventArgs e)
protected virtual bool CanDragOver(DropPosition dropPosition, TreeNodeElement targetNodeElement)
Determines whether the service may be started. Validation is as follows:
- Check whether Enabled is true.
- Check the context through IsContextValid method. An exception is thrown if context is invalid.
- Checks the current state - it should be Initial or Stopped.
Creates a new tree node in the target RadTreeView using the information from the source tree.
protected virtual RadTreeNode CreateTreeNode(RadTreeNode sourceTreeNode)
The source tree node.
Returns:A new instance of RadTreeNode if successfull.
protected virtual void DisposeHint()
Releases managed resources by clearing the property store and disposing value animators to prevent memory leaks.
protected override void DisposeManagedResources()
Overrides:
protected virtual List<RadTreeNode> GetDraggedNodes(RadTreeNode draggedNode)
List<RadTreeNode>
protected DropPosition GetDropPosition(Point dropLocation, TreeNodeElement targetNodeElement)
protected virtual List<RadTreeNode> GetSelectedNodes(RadTreeNode draggedNode)
List<RadTreeNode>
protected override void HandleMouseMove(Point mousePosition)
Overrides:
public void HideHintWindow()
protected override bool IsDropTargetValid(ISupportDrop dropTarget)
Overrides:
protected override void OnPreviewDragDrop(RadDropEventArgs e)
Overrides:
protected override void OnPreviewDragHint(PreviewDragHintEventArgs e)
Overrides:
protected virtual void OnPreviewDragHintWithDropPosition(TreeViewPreviewDragHintEventArgs e)
protected override void OnPreviewDragOver(RadDragOverEventArgs e)
Overrides:
Notifies that the service has been successfully started. Allows inheritors to perform some additional logic upon start.
protected override void OnStarted()
Overrides:
Notifies that a running operation has stopped. Allows inheritors to perform some additional logic upon stop.
protected override void OnStopped()
Overrides:
Notifies that a stop request has occured. Cancelable.
protected override void OnStopping(RadServiceStoppingEventArgs e)
Overrides:
protected virtual void PerformDragDrop(Point dropLocation, TreeNodeElement targetNodeElement, List<RadTreeNode> draggedNodes)
protected virtual void PerformDragDropCore(DropPosition position, RadTreeNode targetNode, List<RadTreeNode> draggedNodes)
Performs the core Start logic.
protected override void PerformStart()
Overrides:
Stops the service. Performs the core logic.
protected override void PerformStop()
Overrides:
protected virtual void PrepareDragHint(TreeNodeElement nodeElement)
public void ShowHintWindow()