Fix scroll pool inserting off-by-one

This commit is contained in:
Sinai 2021-05-20 20:22:45 +10:00
parent 084aee617c
commit e270f205a1
2 changed files with 2 additions and 2 deletions

View File

@ -19,7 +19,7 @@ namespace UnityExplorer
public static class ExplorerCore
{
public const string NAME = "UnityExplorer";
public const string VERSION = "4.0.2";
public const string VERSION = "4.0.3";
public const string AUTHOR = "Sinai";
public const string GUID = "com.sinai.unityexplorer";

View File

@ -298,7 +298,7 @@ namespace UnityExplorer.UI.Widgets
if (CellPool.Count > 1)
{
int index = CellPool.Count - 1 - (topPoolIndex % (CellPool.Count - 1));
cell.Rect.SetSiblingIndex(index);
cell.Rect.SetSiblingIndex(index + 1);
if (bottomPoolIndex == index - 1)
bottomPoolIndex++;