2025-02-09 23:47:42 -05:00
|
|
|
using System.Collections;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using Ichni.RhythmGame;
|
2025-02-12 01:57:18 +08:00
|
|
|
using Unity.VisualScripting;
|
2025-02-09 23:47:42 -05:00
|
|
|
using UnityEngine;
|
2025-02-10 15:56:10 +08:00
|
|
|
using UnityEngine.UI;
|
2025-02-09 23:47:42 -05:00
|
|
|
|
|
|
|
|
namespace Ichni.Editor
|
|
|
|
|
{
|
|
|
|
|
public class Hierarchy : StaticWindow
|
|
|
|
|
{
|
|
|
|
|
public GameObject hierarchyTabPrefab;
|
|
|
|
|
public RectTransform tabContainer;
|
|
|
|
|
public List<HierarchyTab> tabList;
|
2025-02-11 22:58:56 -05:00
|
|
|
|
|
|
|
|
public HierarchyTab GenerateTab(GameElement targetElement, GameElement parentElement)
|
2025-02-09 23:47:42 -05:00
|
|
|
{
|
2025-02-11 22:58:56 -05:00
|
|
|
HierarchyTab tab = Instantiate(hierarchyTabPrefab, tabContainer).GetComponent<HierarchyTab>();
|
2025-02-12 01:57:18 +08:00
|
|
|
//if(parentElement.connectedTab!=null)tab.transform.SetSiblingIndex(parentElement.connectedTab.transform.GetSiblingIndex());
|
2025-02-09 23:47:42 -05:00
|
|
|
tab.SetTab(targetElement, parentElement);
|
2025-02-12 01:57:18 +08:00
|
|
|
return tab;
|
2025-02-09 23:47:42 -05:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|