PhysicalPressEventRouter Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
This class exists to route PressableButton events through to Interactable. The result is being able to have physical touch call Interactable.OnPointerClicked.
public ref class PhysicalPressEventRouter : UnityEngine::MonoBehaviour
[UnityEngine.AddComponentMenu("Scripts/MRTK/SDK/PhysicalPressEventRouter")]
public class PhysicalPressEventRouter : UnityEngine.MonoBehaviour
[<UnityEngine.AddComponentMenu("Scripts/MRTK/SDK/PhysicalPressEventRouter")>]
type PhysicalPressEventRouter = class
inherit MonoBehaviour
Public Class PhysicalPressEventRouter
Inherits MonoBehaviour
- Inheritance
-
UnityEngine.MonoBehaviourPhysicalPressEventRouter
- Attributes
-
UnityEngine.AddComponentMenuAttribute
Constructors
PhysicalPressEventRouter() |
Fields
InteractableOnClick | |
routingTarget |
Methods
OnHandPressCompleted() |
Gets called when the ButtonReleased event is invoked within the default PressableButton and PressableButtonHoloLens2 components. Once the physical press with a hand is completed, set the press and physical touch states within Interactable |
OnHandPressTouched() |
Gets called when the TouchBegin event is invoked within the default PressableButton and PressableButtonHoloLens2 components. When the physical touch with a hand has begun, set physical touch state within Interactable. |
OnHandPressTriggered() |
Gets called when the ButtonPressed event is invoked within the default PressableButton and PressableButtonHoloLens2 components. When the physical press with a hand is triggered, set the physical touch and press state within Interactable. |
OnHandPressUntouched() |
Gets called when the TouchEnd event is invoked within the default PressableButton and PressableButtonHoloLens2 components. Once the physical touch with a hand is removed, set the physical touch and possibly press state within Interactable. |