using UnityEngine;
using UnityEngine.UI;
using UnityEngine.Events;
using AX.MessageSystem;
public class TipWindowManager : MonoBehaviour {
public UnityAction OKFunction { get; set; }
public UnityAction NOFunction { get; set; }
///
/// 不参与记录
///
///
///
///
public void SetWindow(string tips, UnityAction OKFunctions, UnityAction NOFunctions, UnityAction CloseFunctions)
{
//MessageDispatcher.SendMessage("SHOW_SCREEN_MASK", gameObject);
OKFunction = OKFunctions;
NOFunction = NOFunctions == null ? () => { DestroyWindow(); } : NOFunctions;
CloseFunctions = DestroyWindow;
transform.name = "TheTipWindow";
transform.SetParent(GameObject.Find("Canvas").transform);
if (transform.parent.GetComponent().referenceResolution.x != 1920)
{
transform.localScale = new Vector3(0.6f, 0.6f, 1);
}
else
{
transform.localScale = new Vector3(1, 1, 1);
}
GetComponent().anchoredPosition = new Vector2(0, 40);
transform.Find("Text").GetComponent().text = tips;
//transform.Find("sure").GetComponent