/// <summary> /// Редактирование данных фигур. /// </summary> void dataGridViewFigures_Click(object sender, EventArgs e) { if (figures.Any()) { var n = dataGridViewFigures.CurrentRow.Index; if (n <= figures.Count) { form = new AddFigure(figures, n); form.DataFigures += DataFigureChange; form.Show(); } } }
/// <summary> /// Кнопка вызова формы добавления фигур. /// </summary> void buttonAddFigure_Click(object sender, EventArgs e) { form = new AddFigure(figures); form.DataFigures += DataFigureChange; form.Show(); }