Class InputSystemUIInputModule | Package Manager UI website
docs.unity3d.com
    Show / Hide Table of Contents

    Class InputSystemUIInputModule

    Input module that takes its input from InputAction.

    Inheritance
    System.Object
    UIInputModule
    InputSystemUIInputModule
    Inherited Members
    UIInputModule.ActivateModule()
    UIInputModule.repeatDelay
    UIInputModule.repeatRate
    UIInputModule.trackedDeviceDragThresholdMultiplier
    Namespace: UnityEngine.InputSystem.Plugins.UI
    Syntax
    public class InputSystemUIInputModule : UIInputModule
    Remarks

    This UI input module has the advantage over other such modules that it doesn't have to know what devices and types of devices input is coming from. Instead, the actions hide the actual sources of input from the module.

    Properties

    actionsAsset

    Declaration
    public InputActionAsset actionsAsset { get; set; }
    Property Value
    Type Description
    InputActionAsset

    cancel

    An InputAction delivering a System.Boolean used for sending events.

    Declaration
    public InputActionReference cancel { get; set; }
    Property Value
    Type Description
    InputActionReference

    leftClick

    An InputAction delivering a System.Boolean used for sending events.

    Declaration
    public InputActionReference leftClick { get; set; }
    Property Value
    Type Description
    InputActionReference

    middleClick

    An InputAction delivering a System.Boolean used for sending events.

    Declaration
    public InputActionReference middleClick { get; set; }
    Property Value
    Type Description
    InputActionReference

    move

    An InputAction delivering a 2D motion vector. used for sending events.

    Declaration
    public InputActionReference move { get; set; }
    Property Value
    Type Description
    InputActionReference

    point

    An InputAction delivering a 2D screen position. used as a cursor for pointing at UI elements.

    Declaration
    public InputActionReference point { get; set; }
    Property Value
    Type Description
    InputActionReference

    rightClick

    An InputAction delivering a System.Boolean used for sending events.

    Declaration
    public InputActionReference rightClick { get; set; }
    Property Value
    Type Description
    InputActionReference

    scrollWheel

    An InputAction delivering a scroll wheel value. used for sending events.

    Declaration
    public InputActionReference scrollWheel { get; set; }
    Property Value
    Type Description
    InputActionReference

    submit

    An InputAction delivering a System.Boolean used for sending events.

    Declaration
    public InputActionReference submit { get; set; }
    Property Value
    Type Description
    InputActionReference

    Methods

    AddTouch(InputActionProperty, InputActionProperty)

    Adds Touch UI responses based the Actions provided.

    Declaration
    public int AddTouch(InputActionProperty position, InputActionProperty phase)
    Parameters
    Type Name Description
    InputActionProperty position

    A screen space value that represents the position of the touch.

    InputActionProperty phase

    A PointerPhase value that represents the current state of the touch event.

    Returns
    Type Description
    System.Int32

    The Pointer Id that represents UI events from this Touch action set.

    AddTrackedDevice(InputActionProperty, InputActionProperty, InputActionProperty)

    Adds Tracked Device UI responses based the Actions provided.

    Declaration
    public int AddTrackedDevice(InputActionProperty position, InputActionProperty orientation, InputActionProperty select)
    Parameters
    Type Name Description
    InputActionProperty position

    A unity world space position that represents the position in the world of the device.

    InputActionProperty orientation

    A rotation value representing the orientation of the device.

    InputActionProperty select

    A System.Boolean selection value that represents whether the user wants to select objects or not.

    Returns
    Type Description
    System.Int32

    The Pointer Id that represents UI events from this Touch action set.

    Awake()

    Declaration
    protected override void Awake()

    DisableAllActions()

    This is a quick accessor for disabling all actions currently enabled. Currently, action ownership is ambiguous, and we need a way to enable/disable inspector-set actions.

    Declaration
    public void DisableAllActions()

    EnableAllActions()

    This is a quick accessor for enabling all actions. Currently, action ownership is ambiguous, and we need a way to enable/disable inspector-set actions.

    Declaration
    public void EnableAllActions()

    OnDestroy()

    Declaration
    protected override void OnDestroy()

    OnDisable()

    Declaration
    protected override void OnDisable()

    OnEnable()

    Declaration
    protected override void OnEnable()

    Process()

    Declaration
    public override void Process()
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023