From c7e2d8f773baa3955f17402b842eb43329c5f3a0 Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 7 Apr 2021 21:06:10 +0800 Subject: +UI_Effect --- Assets/Test/00_EventSystem/CapsuleButton.cs | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 Assets/Test/00_EventSystem/CapsuleButton.cs (limited to 'Assets/Test/00_EventSystem/CapsuleButton.cs') diff --git a/Assets/Test/00_EventSystem/CapsuleButton.cs b/Assets/Test/00_EventSystem/CapsuleButton.cs new file mode 100644 index 0000000..b72e5bd --- /dev/null +++ b/Assets/Test/00_EventSystem/CapsuleButton.cs @@ -0,0 +1,24 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; +using UnityEngine.EventSystems; + +public class CapsuleButton : MonoBehaviour, IPointerDownHandler, IPointerUpHandler, IPointerClickHandler +{ + public virtual void OnPointerClick(PointerEventData eventData) + { + Debug.Log("CapsuleButton.OnPointerClick"); + } + + public virtual void OnPointerUp(PointerEventData eventData) + { + Debug.Log("CapsuleButton.OnPointerUp"); + } + + public virtual void OnPointerDown(PointerEventData eventData) + { + Debug.Log("CapsuleButton.OnPointerDown"); + } + +} -- cgit v1.1-26-g67d0