mirror of
https://github.com/unity-atoms/unity-atoms.git
synced 2025-01-24 09:08:23 -05:00
20 lines
642 B
C#
20 lines
642 B
C#
#if UNITY_2019_1_OR_NEWER
|
|
using UnityEditor;
|
|
using UnityEngine.UIElements;
|
|
using UnityAtoms.Editor;
|
|
|
|
namespace UnityAtoms.Mobile.Editor
|
|
{
|
|
[CustomEditor(typeof(TouchUserInputEvent))]
|
|
public sealed class TouchUserInputEventEditor : AtomEventEditor<TouchUserInput, TouchUserInputEvent>
|
|
{
|
|
protected override VisualElement GetRaiseValueInput()
|
|
{
|
|
var input = new Toggle() { label = "Raise value", name = "Raise value", viewDataKey = "Raise value" };
|
|
input.RegisterCallback<ChangeEvent<TouchUserInput>>((evt) => { _raiseValue = evt.newValue; });
|
|
return input;
|
|
}
|
|
}
|
|
}
|
|
#endif
|