/// <summary> /// item 回调 /// </summary> /// <param name="index"></param> public void ItemCallback(int index) { currentIndex = index; for (int i = 0; i < list.Count; i++) { ToggleCell item = list[i]; if (currentIndex == item.index) { item.StartSelect(true); callback(currentIndex); } else { item.StartSelect(false); } } }
/// <summary> /// 添加item /// </summary> /// <param name="it"></param> public void AddToggleItem(ToggleCell it) { it.center = this; list.Add(it); }