布局功能增加黑白名单功能。

This commit is contained in:
2025-09-18 17:17:34 +08:00
parent ddb6806a9b
commit a84e583dec
5 changed files with 140 additions and 12 deletions
@@ -7,7 +7,7 @@ using XericLibrary.Runtime.MacroLibrary;
namespace XericUI.OverrideLayout
{
[AddComponentMenu("Xeric UI Vessel/Layout/Xeric Horizontal Layout Group")]
[AddComponentMenu("Xeric UI Vessel/Layout/Xeric Horizontal Layout Group", 10)]
/// <summary>
/// Layout child layout elements below each other.
/// </summary>
@@ -26,8 +26,7 @@ namespace XericUI.OverrideLayout
for (int i = 0; i < rectTransform.childCount; i++)
{
var rect = rectTransform.GetChild(i) as RectTransform;
if (rect == null ||
(layoutIgnoreInactive && !rect.gameObject.activeInHierarchy))
if (rect == null || CanSkipLayout(rect))
continue;
rect.GetComponents(typeof(ILayoutIgnorer), toIgnoreList);