38 lines
1000 B
C#
38 lines
1000 B
C#
using System;
|
|
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
using ZXKFramework;
|
|
namespace YiLiao.XinFeiTingZhen
|
|
{
|
|
public class ConfirmPanel : UIBase
|
|
{
|
|
public override string GroupName => "ConfirmPanel";
|
|
|
|
public override string Name => "ConfirmPanel";
|
|
|
|
Action callback1;
|
|
Action callback2;
|
|
public override void Init(IUIManager uictrl)
|
|
{
|
|
base.Init(uictrl);
|
|
transform.FindFirst<Button>("repeat").onClick.AddListener(() => {
|
|
callback1?.Invoke();
|
|
SetActive(false);
|
|
});
|
|
transform.FindFirst<Button>("next").onClick.AddListener(() => {
|
|
callback2?.Invoke();
|
|
SetActive(false);
|
|
});
|
|
}
|
|
public void ShowConfirmPanel(Action repeat, Action next)
|
|
{
|
|
SetActive(true);
|
|
callback1 = repeat;
|
|
callback2 = next;
|
|
}
|
|
}
|
|
}
|
|
|