mirror of
https://github.com/codewriter-packages/Tri-Inspector.git
synced 2025-01-22 08:18:49 -05:00
Layout improvements
This commit is contained in:
parent
20faf1bef5
commit
bd1fc4935b
@ -32,7 +32,17 @@ namespace TriInspector.Elements
|
|||||||
|
|
||||||
public sealed override float GetHeight(float width)
|
public sealed override float GetHeight(float width)
|
||||||
{
|
{
|
||||||
return GetContentHeight(width) + GetHeaderHeight(width) + InsetTop + InsetBottom;
|
var headerHeight = GetHeaderHeight(width);
|
||||||
|
var contentHeight = GetContentHeight(width);
|
||||||
|
|
||||||
|
var height = headerHeight + contentHeight;
|
||||||
|
|
||||||
|
if (contentHeight > 0)
|
||||||
|
{
|
||||||
|
height += InsetTop + InsetBottom;
|
||||||
|
}
|
||||||
|
|
||||||
|
return height;
|
||||||
}
|
}
|
||||||
|
|
||||||
public sealed override void OnGUI(Rect position)
|
public sealed override void OnGUI(Rect position)
|
||||||
|
Loading…
Reference in New Issue
Block a user