public void ClearItems() { activeStep = null; while (m_StepItems.Count > 0) { IStepItem item = m_StepItems[0]; m_StepItems.RemoveAt(0); item.Dispose(); } stepsChanged.Invoke(m_StepItems); }
public void RemoveStepAt(int index) { if (index == -1 || index >= m_StepItems.Count) { return; } IStepItem item = m_StepItems[index]; if (item == activeStep) { activeStep = null; } m_StepItems.RemoveAt(index); item.Dispose(); stepsChanged.Invoke(m_StepItems); }