mirror of
https://github.com/GrahamKracker/UnityExplorer.git
synced 2025-01-05 17:13:22 +08:00
Cleanup
This commit is contained in:
parent
7d961ce8ad
commit
bc64a04339
@ -29,8 +29,8 @@ namespace UnityExplorer.ObjectExplorer
|
|||||||
SceneHandler.OnLoadedScenesChanged += SceneHandler_OnLoadedScenesChanged;
|
SceneHandler.OnLoadedScenesChanged += SceneHandler_OnLoadedScenesChanged;
|
||||||
}
|
}
|
||||||
|
|
||||||
public override GameObject UIRoot => m_uiRoot;
|
public override GameObject UIRoot => uiRoot;
|
||||||
private GameObject m_uiRoot;
|
private GameObject uiRoot;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Whether to automatically update per auto-update interval or not.
|
/// Whether to automatically update per auto-update interval or not.
|
||||||
@ -180,13 +180,13 @@ namespace UnityExplorer.ObjectExplorer
|
|||||||
|
|
||||||
public override void ConstructUI(GameObject content)
|
public override void ConstructUI(GameObject content)
|
||||||
{
|
{
|
||||||
m_uiRoot = UIFactory.CreateUIObject("SceneExplorer", content);
|
uiRoot = UIFactory.CreateUIObject("SceneExplorer", content);
|
||||||
UIFactory.SetLayoutGroup<VerticalLayoutGroup>(m_uiRoot, true, true, true, true, 0, 2, 2, 2, 2);
|
UIFactory.SetLayoutGroup<VerticalLayoutGroup>(uiRoot, true, true, true, true, 0, 2, 2, 2, 2);
|
||||||
UIFactory.SetLayoutElement(m_uiRoot, flexibleHeight: 9999);
|
UIFactory.SetLayoutElement(uiRoot, flexibleHeight: 9999);
|
||||||
|
|
||||||
// Tool bar (top area)
|
// Tool bar (top area)
|
||||||
|
|
||||||
var toolbar = UIFactory.CreateVerticalGroup(m_uiRoot, "Toolbar", true, true, true, true, 2, new Vector4(2, 2, 2, 2),
|
var toolbar = UIFactory.CreateVerticalGroup(uiRoot, "Toolbar", true, true, true, true, 2, new Vector4(2, 2, 2, 2),
|
||||||
new Color(0.15f, 0.15f, 0.15f));
|
new Color(0.15f, 0.15f, 0.15f));
|
||||||
|
|
||||||
// Scene selector dropdown
|
// Scene selector dropdown
|
||||||
@ -240,7 +240,7 @@ namespace UnityExplorer.ObjectExplorer
|
|||||||
|
|
||||||
// Transform Tree
|
// Transform Tree
|
||||||
|
|
||||||
var scrollPool = UIFactory.CreateScrollPool<TransformCell>(m_uiRoot, "TransformTree", out GameObject scrollObj,
|
var scrollPool = UIFactory.CreateScrollPool<TransformCell>(uiRoot, "TransformTree", out GameObject scrollObj,
|
||||||
out GameObject scrollContent, new Color(0.11f, 0.11f, 0.11f));
|
out GameObject scrollContent, new Color(0.11f, 0.11f, 0.11f));
|
||||||
UIFactory.SetLayoutElement(scrollObj, flexibleHeight: 9999);
|
UIFactory.SetLayoutElement(scrollObj, flexibleHeight: 9999);
|
||||||
UIFactory.SetLayoutElement(scrollContent, flexibleHeight: 9999);
|
UIFactory.SetLayoutElement(scrollContent, flexibleHeight: 9999);
|
||||||
@ -312,7 +312,7 @@ namespace UnityExplorer.ObjectExplorer
|
|||||||
{
|
{
|
||||||
if (SceneHandler.WasAbleToGetScenesInBuild)
|
if (SceneHandler.WasAbleToGetScenesInBuild)
|
||||||
{
|
{
|
||||||
var sceneLoaderObj = UIFactory.CreateVerticalGroup(m_uiRoot, "SceneLoader", true, true, true, true);
|
var sceneLoaderObj = UIFactory.CreateVerticalGroup(uiRoot, "SceneLoader", true, true, true, true);
|
||||||
UIFactory.SetLayoutElement(sceneLoaderObj, minHeight: 25);
|
UIFactory.SetLayoutElement(sceneLoaderObj, minHeight: 25);
|
||||||
|
|
||||||
// Title
|
// Title
|
||||||
|
Loading…
x
Reference in New Issue
Block a user