diff --git a/src/UI/Widgets/ScrollPool/ScrollPool.cs b/src/UI/Widgets/ScrollPool/ScrollPool.cs index ec59588..5866284 100644 --- a/src/UI/Widgets/ScrollPool/ScrollPool.cs +++ b/src/UI/Widgets/ScrollPool/ScrollPool.cs @@ -193,12 +193,11 @@ namespace UnityExplorer.UI.Widgets RuntimeProvider.Instance.StartCoroutine(InitCoroutine(onHeightChangedListener)); } - private WaitForEndOfFrame waitForEndOfFrame = new WaitForEndOfFrame(); - private IEnumerator InitCoroutine(Action onHeightChangedListener) { ScrollRect.content.anchoredPosition = Vector2.zero; - yield return waitForEndOfFrame ?? (waitForEndOfFrame = new WaitForEndOfFrame()); + yield return null; + yield return null; LayoutRebuilder.ForceRebuildLayoutImmediate(Content);