示例#1
0
文件: UI.cs 项目: SendSi/SmallGame
        public void AddUIBaseComponent <T>() where T : UIBaseComponent, new()
        {
            T t = this.AddComponent <T>();

            this.UiBaseComponent = t;
        }
示例#2
0
 public K AddUiComponent <K, P1>(P1 p1) where K : UIBaseComponent, new()
 {
     UiComponent = this.AddComponent <K, P1>(p1);
     return((K)UiComponent);
 }
示例#3
0
 public K AddUiComponent <K, P1, P2, P3>(P1 p1, P2 p2, P3 p3) where K : UIBaseComponent, new()
 {
     UiComponent = this.AddComponent <K, P1, P2, P3>(p1, p2, p3);
     return((K)UiComponent);
 }
示例#4
0
 /// <summary>
 /// 添加主UI组件,继承自UIBaseComponent
 /// </summary>
 /// <typeparam name="K"></typeparam>
 /// <returns></returns>
 public K AddUiComponent <K>() where K : UIBaseComponent, new()
 {
     UiComponent = this.AddComponent <K>();
     return((K)UiComponent);
 }