/// <summary> /// Subscribe to the rayHovering event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be called when the event occurs</param> public static void SubscribeToRayHovering(this IUsesUIEvents user, Action <GameObject, TrackedDeviceEventData> action) { user.provider.rayHovering += action; }
/// <summary> /// Subscribe to the dragEnded event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be called when the event occurs</param> public static void SubscribeToDragEnded(this IUsesUIEvents user, Action <GameObject, TrackedDeviceEventData> action) { user.provider.dragEnded += action; }
/// <summary> /// Unsubscribe from the rayExited event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be unsubscribed from the event</param> public static void UnsubscribeFromRayExited(this IUsesUIEvents user, Action <GameObject, TrackedDeviceEventData> action) { user.provider.rayExited -= action; }
/// <summary> /// Subscribe to the pointerUp event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be called when the event occurs</param> public static void SubscribeToPointerUp(this IUsesUIEvents user, Action <GameObject, RayEventData> action) { #if !FI_AUTOFILL user.provider.pointerUp += action; #endif }
/// <summary> /// Unsubscribe from the dragEnded event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be unsubscribed from the event</param> public static void UnsubscribeFromDragEnded(this IUsesUIEvents user, Action <GameObject, RayEventData> action) { #if !FI_AUTOFILL user.provider.dragEnded -= action; #endif }
/// <summary> /// Subscribe to the dragStarted event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be called when the event occurs</param> public static void SubscribeToDragStarted(this IUsesUIEvents user, Action <GameObject, RayEventData> action) { #if !FI_AUTOFILL user.provider.dragStarted += action; #endif }
/// <summary> /// Unsubscribe from the pointerDown event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be unsubscribed from the event</param> public static void UnsubscribeFromPointerDown(this IUsesUIEvents user, Action <GameObject, RayEventData> action) { #if !FI_AUTOFILL user.provider.pointerDown -= action; #endif }
/// <summary> /// Unsubscribe from the rayHovering event /// </summary> /// <param name="user">The functionality user</param> /// <param name="action">The action which will be unsubscribed from the event</param> public static void UnsubscribeFromRayHovering(this IUsesUIEvents user, Action <GameObject, RayEventData> action) { #if !FI_AUTOFILL user.provider.rayHovering -= action; #endif }