Editar

Partilhar via


PointerClickHandler Class

Definition

Caution

Use PointerHandler instead of PointerClickHandler

This component handles pointer clicks from all types of input sources.

i.e. a primary mouse button click, motion controller selection press, or hand tap.

public ref class PointerClickHandler : Microsoft::MixedReality::Toolkit::Input::BaseInputHandler, Microsoft::MixedReality::Toolkit::Input::IMixedRealityPointerHandler, UnityEngine::EventSystems::IEventSystemHandler
[System.Obsolete("Use PointerHandler instead of PointerClickHandler", true)]
[UnityEngine.AddComponentMenu("Scripts/MRTK/Obsolete/PointerClickHandler")]
public class PointerClickHandler : Microsoft.MixedReality.Toolkit.Input.BaseInputHandler, Microsoft.MixedReality.Toolkit.Input.IMixedRealityPointerHandler, UnityEngine.EventSystems.IEventSystemHandler
[<System.Obsolete("Use PointerHandler instead of PointerClickHandler", true)>]
[<UnityEngine.AddComponentMenu("Scripts/MRTK/Obsolete/PointerClickHandler")>]
type PointerClickHandler = class
    inherit BaseInputHandler
    interface IMixedRealityPointerHandler
    interface IEventSystemHandler
Public Class PointerClickHandler
Inherits BaseInputHandler
Implements IEventSystemHandler, IMixedRealityPointerHandler
Inheritance
UnityEngine.MonoBehaviour
PointerClickHandler
Attributes
ObsoleteAttribute UnityEngine.AddComponentMenuAttribute
Implements
IMixedRealityPointerHandler UnityEngine.EventSystems.IEventSystemHandler

Constructors

PointerClickHandler()

Properties

IsFocusRequired

Is Focus required to receive input events on this GameObject?

(Inherited from BaseInputHandler)

Methods

EnsureInputSystemValid()

A task that will only complete when the input system has in a valid state.

(Inherited from InputSystemGlobalHandlerListener)
OnDisable() (Inherited from BaseInputHandler)
OnEnable() (Inherited from BaseInputHandler)
OnPointerClicked(MixedRealityPointerEventData)

When a pointer clicked event is raised, this method is used to pass along the event data to the input handler.

OnPointerDown(MixedRealityPointerEventData)

When a pointer down event is raised, this method is used to pass along the event data to the input handler.

OnPointerDragged(MixedRealityPointerEventData)

Called every frame a pointer is down. Can be used to implement drag-like behaviors.

OnPointerUp(MixedRealityPointerEventData)

When a pointer up event is raised, this method is used to pass along the event data to the input handler.

RegisterHandlers()

Overload this method to specify, which global events component wants to listen to. Use RegisterHandler API of InputSystem

Start() (Inherited from BaseInputHandler)
UnregisterHandlers()

Overload this method to specify, which global events component should stop listening to. Use UnregisterHandler API of InputSystem

Update() (Inherited from BaseInputHandler)

Applies to