NanDaEnvironmentalProtection/Assets/Scripts/UI/UIPanel/UI_UpBgPanel.cs

87 lines
2.5 KiB
C#

using DG.Tweening;
using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting;
using UnityEngine;
using UnityEngine.UI;
/// <summary>
/// 下方面板
/// </summary>
public class UI_UpBgPanel : BasePanel
{
public static UI_UpBgPanel instance;
public ToggleGroup AllToggle_Tg;
public List<Toggle> toggle_Up = new List<Toggle>();
public UpToggleState UpToggleState = UpToggleState.;
protected override void Awake()
{
base.Awake();
AllToggle_Tg = GetControl<ToggleGroup>("AllToggle_Tg");
foreach (Toggle itemToggle in toggle_Up)
{
itemToggle.group = AllToggle_Tg;
}
instance = this;
}
public override void ShowMe()
{
base.ShowMe();
Debug.Log("UI_LoadingPanel ShowMe");
}
public override void HideMe()
{
base.HideMe();
Debug.Log("UI_LoadingPanel HideMe");
}
private void Update()
{
}
protected override void OnChangeToggle(string btnPath ,bool ison)
{
base.OnChangeToggle(btnPath, ison);
if (ison)
{
switch (btnPath)
{
case "驾驶室":
UpToggleState = UpToggleState.;
Manager.Instance.isForDetails = false;
Debug.Log(btnPath);
break;
case "企业信息管理":
UpToggleState = UpToggleState.;
Debug.Log(btnPath);
break;
case "环保手续情况":
UpToggleState = UpToggleState.;
Manager.Instance.isForDetails = false;
Debug.Log(btnPath);
break;
case "环境治理现状":
UpToggleState = UpToggleState.;
Manager.Instance.isForDetails = false;
Debug.Log(btnPath);
break;
case "园区在线检测":
UpToggleState = UpToggleState.线;
Manager.Instance.isForDetails = false;
Debug.Log(btnPath);
break;
case "污染排放管理":
UpToggleState = UpToggleState.;
Manager.Instance.isForDetails = false;
Debug.Log(btnPath);
break;
}
}
}
}