diff options
Diffstat (limited to 'Assets/Test/00_EventSystem')
-rw-r--r-- | Assets/Test/00_EventSystem/CapsuleButton.cs | 24 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/CapsuleButton.cs.meta | 11 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/CustomInputModule.cs | 14 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/CustomInputModule.cs.meta | 11 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/Description.cs | 11 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/Description.cs.meta | 11 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/PicoButton.cs | 24 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/PicoButton.cs.meta | 11 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/Test.cs | 23 | ||||
-rw-r--r-- | Assets/Test/00_EventSystem/Test.cs.meta | 13 |
10 files changed, 153 insertions, 0 deletions
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"); + } + +} diff --git a/Assets/Test/00_EventSystem/CapsuleButton.cs.meta b/Assets/Test/00_EventSystem/CapsuleButton.cs.meta new file mode 100644 index 0000000..7ec7b59 --- /dev/null +++ b/Assets/Test/00_EventSystem/CapsuleButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 71800034947a58040a0004d4225a9007 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Test/00_EventSystem/CustomInputModule.cs b/Assets/Test/00_EventSystem/CustomInputModule.cs new file mode 100644 index 0000000..c41eb63 --- /dev/null +++ b/Assets/Test/00_EventSystem/CustomInputModule.cs @@ -0,0 +1,14 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.EventSystems; + +public class CustomInputModule : BaseInputModule
+{
+ public override void Process()
+ {
+
+
+ // throw new System.NotImplementedException();
+ } +} diff --git a/Assets/Test/00_EventSystem/CustomInputModule.cs.meta b/Assets/Test/00_EventSystem/CustomInputModule.cs.meta new file mode 100644 index 0000000..3fbdf31 --- /dev/null +++ b/Assets/Test/00_EventSystem/CustomInputModule.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: abe4edfc993b886448942ebeb2e4ff0b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Test/00_EventSystem/Description.cs b/Assets/Test/00_EventSystem/Description.cs new file mode 100644 index 0000000..c412785 --- /dev/null +++ b/Assets/Test/00_EventSystem/Description.cs @@ -0,0 +1,11 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class Description : MonoBehaviour { + + [TextArea(50, 50)] + public string description; + + +} diff --git a/Assets/Test/00_EventSystem/Description.cs.meta b/Assets/Test/00_EventSystem/Description.cs.meta new file mode 100644 index 0000000..8b001ff --- /dev/null +++ b/Assets/Test/00_EventSystem/Description.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 86f7c491fe972c547b8e572c53f94d5b +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Test/00_EventSystem/PicoButton.cs b/Assets/Test/00_EventSystem/PicoButton.cs new file mode 100644 index 0000000..385f90f --- /dev/null +++ b/Assets/Test/00_EventSystem/PicoButton.cs @@ -0,0 +1,24 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; +using UnityEngine.EventSystems; + +public class PicoButton : MonoBehaviour, IPointerDownHandler, IPointerUpHandler, IPointerClickHandler +{ + public virtual void OnPointerClick(PointerEventData eventData) + { + Debug.Log("PicoButton.OnPointerClick"); + } + + public virtual void OnPointerUp(PointerEventData eventData) + { + Debug.Log("PicoButton.OnPointerUp"); + } + + public virtual void OnPointerDown(PointerEventData eventData) + { + Debug.Log("PicoButton.OnPointerDown"); + } + +} diff --git a/Assets/Test/00_EventSystem/PicoButton.cs.meta b/Assets/Test/00_EventSystem/PicoButton.cs.meta new file mode 100644 index 0000000..76c9e9b --- /dev/null +++ b/Assets/Test/00_EventSystem/PicoButton.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8048cdebd1089744b99076ef93c3f3b2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Test/00_EventSystem/Test.cs b/Assets/Test/00_EventSystem/Test.cs new file mode 100644 index 0000000..69d4549 --- /dev/null +++ b/Assets/Test/00_EventSystem/Test.cs @@ -0,0 +1,23 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class Test : MonoBehaviour { + + // Use this for initialization + void Start () { + + } + + // Update is called once per frame + void Update () { + + } + + public void OnClickCallback() + { + Debug.Log("OnClicked!!!"); + } + + +} diff --git a/Assets/Test/00_EventSystem/Test.cs.meta b/Assets/Test/00_EventSystem/Test.cs.meta new file mode 100644 index 0000000..472b16d --- /dev/null +++ b/Assets/Test/00_EventSystem/Test.cs.meta @@ -0,0 +1,13 @@ +fileFormatVersion: 2 +guid: 888d6900b9dcda148bf20be9c4b300c9 +timeCreated: 1602121488 +licenseType: Free +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {fileID: 10300, guid: 0000000000000000f000000000000000, type: 0} + userData: + assetBundleName: + assetBundleVariant: |