Class DragAssetToHierarchy<T>
This class allows for the easy creation of asset to hierarchy dragging actions. Very similar to those native to Unity objects. (E.g. dragging an Sprite to the hierarchy creates a new object containing that sprite).
Inheritance
System.Object
UnityEngine.Object
UnityEngine.ScriptableObject
UnityEditor.Editor
DragAssetToHierarchy<T>
Namespace: InsaneScatterbrain.Tools.Editor
Syntax
[InitializeOnLoad]
public abstract class DragAssetToHierarchy<T> : Editor, IPreviewable, IToolModeOwner where T : Object
Type Parameters
Name | Description |
---|---|
T |
Events
DraggedOnToEmpty
This action gets executed when an asset (or assets) are dragged onto the hierarchy window and not an object in that window.
Declaration
protected static event Action<IList<T>> DraggedOnToEmpty
Event Type
Type | Description |
---|---|
System.Action<System.Collections.Generic.IList<T>> |
DraggedOnToExistingObject
This action gets executed when an asset is dragged onto an existing object.
Declaration
protected static event Action<GameObject, IList<T>> DraggedOnToExistingObject
Event Type
Type | Description |
---|---|
System.Action<UnityEngine.GameObject, System.Collections.Generic.IList<T>> |