Files

26 lines
623 B
C#
Raw Permalink Normal View History

2025-08-11 14:04:06 -04:00
using System.Collections;
using System.Collections.Generic;
2025-08-22 14:54:40 -04:00
using I2.Loc;
using TMPro;
2025-08-11 14:04:06 -04:00
using UnityEngine;
using UnityEngine.UI;
namespace Ichni.UI
{
public class TextButton : SettingsUIElementBase
{
public Button button;
2025-08-22 14:54:40 -04:00
public TMP_Text buttonText;
public void SetUp(string title, string subTitle, string textContent)
2025-08-11 14:04:06 -04:00
{
2025-08-22 14:54:40 -04:00
base.SetUp(title, subTitle);
buttonText.GetComponent<Localize>().SetTerm(textContent);
2025-08-11 14:04:06 -04:00
button.onClick.AddListener(() =>
{
updateValueAction?.Invoke();
});
}
}
}