120 lines
3.2 KiB
C#
120 lines
3.2 KiB
C#
using System;
|
|
using System.ComponentModel;
|
|
using System.Security.Cryptography;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
using XRLib.UI;
|
|
|
|
namespace Studio.UI
|
|
{
|
|
public class Panel_SelectLogic : PanelBase
|
|
{
|
|
public Button Button_AppSetting;
|
|
public Button Button_Authentication;
|
|
public Button Button_Language;
|
|
public Button Button_Logging;
|
|
public Button Button_APIConnection;
|
|
public Button Button_MQTTConnection;
|
|
public Button Button_Create3DObject;
|
|
public Button Button_CreateUI;
|
|
|
|
public Button Button_Close;
|
|
|
|
public Action<ELogic> onClickAppSetting;
|
|
public Action<ELogic> onClickAuthentication;
|
|
public Action<ELogic> onClickLanguage;
|
|
public Action<ELogic> onClickLogging;
|
|
public Action<ELogic> onClickAPIConnection;
|
|
public Action<ELogic> onClickMQTTConnection;
|
|
public Action<ELogic> onClickCreate3DObject;
|
|
public Action<ELogic> onClickCreateUI;
|
|
|
|
|
|
public override void AfterAwake()
|
|
{
|
|
Button_AppSetting.onClick.AddListener(OnClickAppSetting);
|
|
Button_Authentication.onClick.AddListener(OnClickAuthentication);
|
|
Button_Language.onClick.AddListener(OnClickLanguage);
|
|
Button_Logging.onClick.AddListener(OnClickLogging);
|
|
Button_APIConnection.onClick.AddListener(OnClickAPIConnection);
|
|
Button_MQTTConnection.onClick.AddListener(OnClickMQTTConnection);
|
|
Button_Create3DObject.onClick.AddListener(OnClickCreate3DObject);
|
|
Button_CreateUI.onClick.AddListener(OnClickCreateUI);
|
|
|
|
Button_Close.onClick.AddListener(() => Open(false));
|
|
}
|
|
|
|
public void Open(bool isOpen)
|
|
{
|
|
SetActive(isOpen);
|
|
}
|
|
|
|
public void OnClickAppSetting()
|
|
{
|
|
onClickAppSetting?.Invoke(ELogic.AppSetting);
|
|
}
|
|
|
|
public void OnClickAuthentication()
|
|
{
|
|
onClickAuthentication?.Invoke(ELogic.Authentication);
|
|
}
|
|
|
|
public void OnClickLanguage()
|
|
{
|
|
onClickLanguage?.Invoke(ELogic.Language);
|
|
}
|
|
|
|
public void OnClickLogging()
|
|
{
|
|
onClickLogging?.Invoke(ELogic.Logging);
|
|
}
|
|
|
|
public void OnClickAPIConnection()
|
|
{
|
|
onClickAPIConnection?.Invoke(ELogic.APIConnection);
|
|
}
|
|
|
|
public void OnClickMQTTConnection()
|
|
{
|
|
onClickMQTTConnection?.Invoke(ELogic.MQTTConnection);
|
|
}
|
|
|
|
public void OnClickCreate3DObject()
|
|
{
|
|
onClickCreate3DObject?.Invoke(ELogic.Create3DObject);
|
|
}
|
|
|
|
public void OnClickCreateUI()
|
|
{
|
|
onClickCreateUI?.Invoke(ELogic.CreateUI);
|
|
}
|
|
}
|
|
|
|
public enum ELogic
|
|
{
|
|
[Description("App 설정")]
|
|
AppSetting,
|
|
|
|
[Description("인증")]
|
|
Authentication,
|
|
|
|
[Description("다국어")]
|
|
Language,
|
|
|
|
[Description("로깅")]
|
|
Logging,
|
|
|
|
[Description("API 연결")]
|
|
APIConnection,
|
|
|
|
[Description("MQTT 연결")]
|
|
MQTTConnection,
|
|
|
|
[Description("3D 객체 생성")]
|
|
Create3DObject,
|
|
|
|
[Description("UI 생성")]
|
|
CreateUI
|
|
}
|
|
}
|