Monday, February 21 2022
Tasks
- 整理UI框架
- 每日一题
Notes
创建了UI框架和场景框架
UI Framework
其中包括Base,Concrete,Manager,UITool和UIType
Base
含有BasePanel脚本,是所有UI面板的父类,包含UI面板的状态信息。
BasePanel
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
/// <summary>
/// 所有UI面板的父类,包含UI面板的状态信息
/// </summary>
public class BasePanel
{
/// <summary>
/// UI信息
/// </summary>
public UIType UIType { get; private set; }
/// <summary>
/// UI管理工具
/// </summary>
public UITool UITool { get; private set; }
/// <summary>
/// 面板管理器
/// </summary>
public PanelManager PanelManager { get; private set; }
/// <summary>
/// UI管理器
/// </summary>
public UIManager UIManager { get; private set; }
#region Initialize
/// <summary>
/// 初始化
/// </summary>
/// <param name="uIType"></param>
public BasePanel(UIType uIType) {
UIType = uIType;
}
/// <summary>
/// 初始化UITool
/// </summary>
/// <param name=""></param>
public void Initialize(UITool tool) {