Merge pull request #53 from AlanWeekend/main

修复UIListBase和UILoopListWidget赋值问题
This commit is contained in:
ALEXTANG
2023-10-26 12:49:00 +08:00
committed by GitHub
2 changed files with 2 additions and 5 deletions

View File

@@ -277,7 +277,7 @@ namespace GameLogic
item.SetSelected(false);
}
item = GetItem(selectIndex) as IListSelectItem;
item = GetItem(m_selectIndex) as IListSelectItem;
if (item != null)
{
item.SetSelected(true);

View File

@@ -159,10 +159,7 @@ namespace GameLogic
public List<TItem> GetItemList()
{
m_items.Clear();
for (int i = 0; i < m_itemCache.Count; i++)
{
m_items.Add(m_itemCache[i]);
}
m_items.AddRange(m_itemCache.Values);
return m_items;
}