2020-09-04 21:36:40 +10:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
using UnityEngine;
|
|
|
|
|
|
|
|
|
|
namespace Explorer
|
|
|
|
|
{
|
|
|
|
|
public static class UnstripExtensions
|
|
|
|
|
{
|
|
|
|
|
public static Rect GetLastUnstripped(this GUILayoutGroup group)
|
|
|
|
|
{
|
|
|
|
|
Rect result;
|
2020-09-05 20:27:00 +10:00
|
|
|
|
if (group.m_Cursor > 0 && group.m_Cursor <= group.entries.Count)
|
2020-09-04 21:36:40 +10:00
|
|
|
|
{
|
|
|
|
|
GUILayoutEntry guilayoutEntry = group.entries[group.m_Cursor - 1];
|
|
|
|
|
result = guilayoutEntry.rect;
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
result = GUILayoutEntry.kDummyRect;
|
|
|
|
|
}
|
|
|
|
|
return result;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|