SetupDragAndDrop(SetupDragAndDropArgs)
This function is called when TreeView.CanStartDrag returns true.
Read time 1 minuteLast updated 14 days ago
Definition
- Type: Method
- Namespace: UnityEditor.IMGUI.Controls
- Assembly: UnityEditor
protected virtual void SetupDragAndDrop(TreeView.SetupDragAndDropArgs args)
Parameters
Remarks
Override this function to set the global DragAndDrop state and set which items can be dragged and dropped. Use TreeView.FindRows to convert the dragged IDs to TreeViewItems if needed.
You control TreeView drag and drop in the following order:\
-
override TreeView.CanStartDrag to enable dragging TreeViewItems.\
-
override TreeView.SetupDragAndDrop to set which TreeViewItems are dragged.\
-
override TreeView.HandleDragAndDrop to control the drag and drop behavior of the TreeView.\
Additional Resources: DragAndDrop.