Class OnScreenButton
A button that is visually represented on-screen and triggered by touch or other pointer input.
Inherited Members
UnityEngine.Component.GetComponentInParent<T>(System.Boolean)
UnityEngine.Object.FindObjectsOfType<T>(System.Boolean)
UnityEngine.Object.FindObjectOfType<T>(System.Boolean)
Namespace: UnityEngine.InputSystem.OnScreen
Syntax
[AddComponentMenu("Input/On-Screen Button")]
[HelpURL("https://docs.unity.cn/Packages/com.unity.inputsystem@1.5/manual/OnScreen.html#on-screen-buttons")]
public class OnScreenButton : OnScreenControl, IPointerDownHandler, IPointerUpHandler
Properties
controlPathInternal
Declaration
protected override string controlPathInternal { get; set; }
Property Value
Type | Description |
---|---|
String |
Overrides
Methods
OnPointerDown(PointerEventData)
Declaration
public void OnPointerDown(PointerEventData eventData)
Parameters
Type | Name | Description |
---|---|---|
PointerEventData | eventData |
OnPointerUp(PointerEventData)
Declaration
public void OnPointerUp(PointerEventData eventData)
Parameters
Type | Name | Description |
---|---|---|
PointerEventData | eventData |