private void OnRefreshDynamic(int obj)
 {
     for (int i = 0, index = 0; i < m_applyCount; ++i)
     {
         index = m_layoutGroup.GetUnUsedIndex(index);
         UILayoutGroupItem item = SetLayoutGroupItem(index, i);
         if (item != null)
         {
             m_layoutGroup.RecordIndex(index);
             item.element.index = index;
         }
         index++;
     }
 }
 private void Update()
 {
     for (int i = 0; i < m_releasedItemList.Count; ++i)
     {
         UILayoutGroupItem item = m_releasedItemList[i];
         item.gameObject.SetActive(false);
     }
     m_spareItemList.AddRange(m_releasedItemList);
     m_releasedItemList.Clear();
     if (m_needPrefabHide)
     {
         m_needPrefabHide = false;
         HideAllPrefab();
     }
 }
 private T DrawOutFromList <T>(List <UILayoutGroupItem> list, int prefabIndex) where T : UILayoutGroupItem
 {
     for (int i = 0; i < list.Count; ++i)
     {
         UILayoutGroupItem item = list[i];
         if (item.element.prefabIndex != prefabIndex)
         {
             continue;
         }
         T tItem = item as T;
         if (tItem != null)
         {
             list.RemoveAt(i);
             return(tItem);
         }
     }
     return(null);
 }