mirror of
https://github.com/GrahamKracker/UnityExplorer.git
synced 2025-07-18 00:57:50 +08:00
Cleanup, use Time.realTimeSinceStartup instead of Time.time, add some stuff
This commit is contained in:
@ -72,9 +72,14 @@ namespace UnityExplorer.UI.Inspectors.IValues
|
||||
public virtual GameObject CreateContent(GameObject parent)
|
||||
{
|
||||
UIRoot = UIFactory.CreateUIObject(this.GetType().Name, parent);
|
||||
UIFactory.SetLayoutGroup<HorizontalLayoutGroup>(UIRoot, true, true, true, true, 3, childAlignment: TextAnchor.MiddleLeft);
|
||||
UIRoot.AddComponent<ContentSizeFitter>().verticalFit = ContentSizeFitter.FitMode.PreferredSize;
|
||||
UIFactory.SetLayoutGroup<VerticalLayoutGroup>(UIRoot, true, true, true, true, 3, childAlignment: TextAnchor.MiddleLeft);
|
||||
|
||||
UIFactory.CreateLabel(UIRoot, "Label", "this is an ivalue", TextAnchor.MiddleLeft);
|
||||
UIFactory.CreateInputField(UIRoot, "InputFIeld", "...", out var input);
|
||||
UIFactory.SetLayoutElement(input.gameObject, minHeight: 25, flexibleHeight: 500);
|
||||
input.lineType = InputField.LineType.MultiLineNewline;
|
||||
input.gameObject.AddComponent<ContentSizeFitter>().verticalFit = ContentSizeFitter.FitMode.PreferredSize;
|
||||
|
||||
return UIRoot;
|
||||
}
|
||||
|
Reference in New Issue
Block a user