docs.unity.cn
Search Results for

    Show / Hide Table of Contents

    Class XRUIInputModule

    Custom class for input modules that send UI input in XR.

    Inheritance
    object
    UIBehaviour
    BaseInputModule
    UIInputModule
    XRUIInputModule
    Inherited Members
    UIInputModule.clickSpeed
    UIInputModule.moveDeadzone
    UIInputModule.repeatDelay
    UIInputModule.repeatRate
    UIInputModule.trackedDeviceDragThresholdMultiplier
    UIInputModule.trackedScrollDeltaMultiplier
    UIInputModule.uiCamera
    UIInputModule.Update()
    UIInputModule.Process()
    UIInputModule.SendUpdateEventToSelectedObject()
    UIInputModule.ActivateModule()
    UIInputModule.GetCurrentGameObject(int)
    UIInputModule.IsPointerOverGameObject(int)
    UIInputModule.finalizeRaycastResults
    UIInputModule.pointerEnter
    UIInputModule.pointerExit
    UIInputModule.pointerDown
    UIInputModule.pointerUp
    UIInputModule.pointerClick
    UIInputModule.pointerMove
    UIInputModule.initializePotentialDrag
    UIInputModule.beginDrag
    UIInputModule.drag
    UIInputModule.endDrag
    UIInputModule.drop
    UIInputModule.scroll
    UIInputModule.updateSelected
    UIInputModule.move
    UIInputModule.submit
    UIInputModule.cancel
    BaseInputModule.m_RaycastResultCache
    BaseInputModule.m_InputOverride
    BaseInputModule.FindFirstRaycast(List<RaycastResult>)
    BaseInputModule.DetermineMoveDirection(float, float)
    BaseInputModule.DetermineMoveDirection(float, float, float)
    BaseInputModule.FindCommonRoot(GameObject, GameObject)
    BaseInputModule.HandlePointerExitAndEnter(PointerEventData, GameObject)
    BaseInputModule.GetAxisEventData(float, float, float)
    BaseInputModule.GetBaseEventData()
    BaseInputModule.ShouldActivateModule()
    BaseInputModule.DeactivateModule()
    BaseInputModule.UpdateModule()
    BaseInputModule.IsModuleSupported()
    BaseInputModule.ConvertUIToolkitPointerId(PointerEventData)
    BaseInputModule.input
    BaseInputModule.inputOverride
    BaseInputModule.eventSystem
    UIBehaviour.Awake()
    UIBehaviour.Start()
    UIBehaviour.OnDestroy()
    UIBehaviour.IsActive()
    UIBehaviour.OnValidate()
    UIBehaviour.Reset()
    UIBehaviour.OnRectTransformDimensionsChange()
    UIBehaviour.OnBeforeTransformParentChanged()
    UIBehaviour.OnTransformParentChanged()
    UIBehaviour.OnDidApplyAnimationProperties()
    UIBehaviour.OnCanvasGroupChanged()
    UIBehaviour.OnCanvasHierarchyChanged()
    UIBehaviour.IsDestroyed()
    Namespace: UnityEngine.XR.Interaction.Toolkit.UI
    Assembly: solution.dll
    Syntax
    [AddComponentMenu("Event/XR UI Input Module", 11)]
    [HelpURL("https://docs.unity.cn/Packages/com.unity.xr.interaction.toolkit@3.0/api/UnityEngine.XR.Interaction.Toolkit.UI.XRUIInputModule.html")]
    public class XRUIInputModule : UIInputModule

    Properties

    Name Description
    activeInputMode

    Configures which Active Input Mode will be used in the situation where the Active Input Handling project setting is set to Both.

    cancelAction

    The Input System action to use for cancelling or backing out of a UI element. Must be a ButtonControl Control.

    cancelButton

    Name of the gamepad/joystick button to use for UI cancel or back commands when using the old Input Manager.

    enableBuiltinActionsAsFallback

    When enabled, built-in Input System actions will be used if no Input System UI Actions are assigned. This uses the currently enabled Input System devices: UnityEngine.InputSystem.Mouse.current, UnityEngine.InputSystem.Gamepad.current, and UnityEngine.InputSystem.Joystick.current.

    enableGamepadInput

    If true, will forward gamepad data to UI elements.

    enableJoystickInput

    If true, will forward joystick data to UI elements.

    enableMouseInput

    If true, will forward 2D mouse data to UI elements.

    enableTouchInput

    If true, will forward 2D touch data to UI elements.

    enableXRInput

    If true, will forward 3D tracked device data to UI elements.

    horizontalAxis

    Name of the horizontal axis for UI navigation when using the old Input Manager.

    leftClickAction

    The Input System action to use to determine whether the left button of a pointer is pressed. Must be a ButtonControl Control.

    middleClickAction

    The Input System action to use to determine whether the middle button of a pointer is pressed. Must be a ButtonControl Control.

    navigateAction

    The Input System action to use to navigate the currently active UI. Must be a Vector2Control Control.

    pointAction

    The Input System action to use to move the pointer on the currently active UI. Must be a Vector2Control Control.

    rightClickAction

    The Input System action to use to determine whether the right button of a pointer is pressed. Must be a ButtonControl Control.

    scrollWheelAction

    The Input System action to use to move the pointer on the currently active UI. Must be a Vector2Control Control.

    submitAction

    The Input System action to use for submitting or activating a UI element. Must be a ButtonControl Control.

    submitButton

    Name of the gamepad/joystick button to use for UI selection or submission when using the old Input Manager.

    verticalAxis

    Name of the vertical axis for UI navigation when using the old Input Manager.

    Methods

    Name Description
    DoProcess()

    Process the current tick for the module.

    GetInteractor(int)

    Gets an IUIInteractor from its corresponding Unity UI Pointer Id. This can be used to identify individual Interactors from the underlying UI Events.

    GetTrackedDeviceModel(IUIInteractor, out TrackedDeviceModel)

    Retrieves the UI Model for a selected IUIInteractor.

    OnDisable()

    See MonoBehavior.OnDisable.

    OnEnable()

    See MonoBehavior.OnEnable.

    RegisterInteractor(IUIInteractor)

    Register an IUIInteractor with the UI system. Calling this will enable it to start interacting with UI.

    UnregisterInteractor(IUIInteractor)

    Unregisters an IUIInteractor with the UI system. This cancels all UI Interaction and makes the IUIInteractor no longer able to affect UI.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)