Class PublisherUtils.LeftClickManipulator
Represents a MouseManipulator that allows a visual element to react when left clicked
Inherited Members
Namespace: Unity.Play.Publisher.Editor
Syntax
public class LeftClickManipulator : MouseManipulator, IManipulator
Constructors
LeftClickManipulator(Action<VisualElement>)
Initializes and returns an instance of LeftClickManipulator.
Declaration
public LeftClickManipulator(Action<VisualElement> OnClick)
Parameters
Type | Name | Description |
---|---|---|
Action<VisualElement> | OnClick | The default callback that will be triggered when the element is clicked |
Methods
OnMouseDown(MouseDownEvent)
Called when the mouse is clicked on the target, when the user starts pressing the button
Declaration
protected void OnMouseDown(MouseDownEvent e)
Parameters
Type | Name | Description |
---|---|---|
MouseDownEvent | e |
OnMouseUp(MouseUpEvent)
Called when the mouse is clicked on the target, when the user stops pressing the button
Declaration
protected void OnMouseUp(MouseUpEvent e)
Parameters
Type | Name | Description |
---|---|---|
MouseUpEvent | e |
RegisterCallbacksOnTarget()
Registers the callbacks on the target
Declaration
protected override void RegisterCallbacksOnTarget()
Overrides
UnregisterCallbacksFromTarget()
Unregisters the callbacks on the target
Declaration
protected override void UnregisterCallbacksFromTarget()