备份CatanBuilding瘦身独立工程
This commit is contained in:
75
Assets/Scripts/UI/Setting/AppraisePopupPanel.cs
Normal file
75
Assets/Scripts/UI/Setting/AppraisePopupPanel.cs
Normal file
@@ -0,0 +1,75 @@
|
||||
using asap.core;
|
||||
using GameCore;
|
||||
using tysdk;
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
|
||||
public class AppraisePopupPanel : MonoBehaviour
|
||||
{
|
||||
Button btn_close;
|
||||
Button btn_diss;
|
||||
Button btn_cancel;
|
||||
Button btn_encourage;
|
||||
|
||||
private void Awake()
|
||||
{
|
||||
var config = GContext.container.Resolve<IConfig>();
|
||||
btn_close = transform.Find("btn_close").GetComponent<Button>();
|
||||
btn_cancel = transform.Find("root/btn_cancel/btn_green").GetComponent<Button>();
|
||||
btn_diss = transform.Find("root/btn_diss/btn_green").GetComponent<Button>();
|
||||
btn_encourage = transform.Find("root/btn_encourage/btn_green").GetComponent<Button>();
|
||||
btn_close.onClick.AddListener(() =>
|
||||
{
|
||||
#if AGG
|
||||
using (var e = GEvent.TackEvent("store_rating"))
|
||||
{
|
||||
e.AddContent("select", "close");
|
||||
}
|
||||
#endif
|
||||
Close();
|
||||
});
|
||||
btn_cancel.onClick.AddListener(() =>
|
||||
{
|
||||
#if AGG
|
||||
using (var e = GEvent.TackEvent("store_rating"))
|
||||
{
|
||||
e.AddContent("select", "close");
|
||||
}
|
||||
#endif
|
||||
Close();
|
||||
});
|
||||
btn_diss.onClick.AddListener(() =>
|
||||
{
|
||||
#if AGG
|
||||
using (var e = GEvent.TackEvent("click_support"))
|
||||
{
|
||||
e.AddContent("button_position", 2);
|
||||
}
|
||||
|
||||
using (var e = GEvent.TackEvent("store_rating"))
|
||||
{
|
||||
e.AddContent("select", "aihelp");
|
||||
}
|
||||
#endif
|
||||
AIHelp.AIHelpSupport.Show("E001");
|
||||
|
||||
Close();
|
||||
});
|
||||
|
||||
btn_encourage.onClick.AddListener(() =>
|
||||
{
|
||||
#if AGG
|
||||
using (var e = GEvent.TackEvent("store_rating"))
|
||||
{
|
||||
e.AddContent("select", "rating");
|
||||
}
|
||||
#endif
|
||||
AppRequestReview.RequestReview(config.Get(GConstant.K_APP_Store_URL, string.Empty));
|
||||
Close();
|
||||
});
|
||||
}
|
||||
void Close()
|
||||
{
|
||||
UIManager.Instance.DestroyUI(UITypes.AppraisePopupPanel);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user