21 lines
507 B
C#
21 lines
507 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using BITKit;
|
|
using UnityEngine.UIElements;
|
|
using UnityEngine.Events;
|
|
namespace BITKit.UX
|
|
{
|
|
public class UXDropdown : UXElement<DropdownField>
|
|
{
|
|
public UnityEvent<string> onSet = new();
|
|
public override void OnStart()
|
|
{
|
|
base.OnStart();
|
|
visualElement.RegisterValueChangedCallback(x =>
|
|
{
|
|
onSet.Invoke(x.newValue);
|
|
});
|
|
}
|
|
}
|
|
} |