ShowTextWidgetData.cs 879 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. using Fort23.Core;
  2. using Fort23.UTool;
  3. using UnityEngine.UI;
  4. using UnityEngine;
  5. using System.Collections.Generic;
  6. using Core.UI.UTool.UITween;
  7. using TMPro;
  8. namespace Fort23.Mono
  9. {
  10. public partial class ShowTextWidget
  11. {
  12. #region 自定义数据
  13. private TextMeshProUGUI _text;
  14. public TextMeshProUGUI text
  15. {
  16. get{
  17. if (_text == null)
  18. {
  19. _text = GetUIUnit<TextMeshProUGUI>("text");
  20. }
  21. return _text;
  22. }
  23. }
  24. private UITweenController _anim;
  25. public UITweenController anim
  26. {
  27. get{
  28. if (_anim == null)
  29. {
  30. _anim = GetUIUnit<UITweenController>("anim");
  31. }
  32. return _anim;
  33. }
  34. }
  35. #endregion 自定义数据结束
  36. public override async CTask SetUIGameObject(GameObject gObjectPoolInterface)
  37. {
  38. await base.SetUIGameObject(gObjectPoolInterface);
  39. Init();
  40. }
  41. }
  42. }