using TMPro; using UnityEngine; using UnityEngine.Events; using UnityEngine.UI; public class UI_MessagePanel : BasePanel { /// /// 确定委托 /// private UnityAction sureAction; /// /// 取消委托 /// private UnityAction cancelAction; /// /// 初始化 /// /// /// /// /// public void Init(string title,string content, E_MessageType type,UnityAction sureAction = null, UnityAction cancelAction = null) { GetControl("Text_title").text = title; GetControl("Text_Content").text = content; SelectPromptMode(type); this.sureAction = sureAction; this.cancelAction = cancelAction; } /// /// 选择提示模式 /// /// public void SelectPromptMode(E_MessageType type) { switch (type) { case E_MessageType.Normal: GetControl("Image_NormalBackGround").gameObject.SetActive(true); GetControl