private void BeComAddRuleClick(object sender, EventArgs e) { var rotation = new Rotation(); var rotationForm = new RotationForm(rotation); rotationForm.Location = Location; rotationForm.ShowDialog(); if (rotationForm.Save) { rotation = rotationForm.Rotation; if (BeTabs.SelectedTab.Name.Equals("TabRotations")) { AddCondition(rotation, BeRotations); } } }
private void EditRule(Node node) { if (node.Tag is Rotation) { var rotation = (Rotation)node.Tag; var rotationForm = new RotationForm(rotation); rotationForm.Location = Location; rotationForm.ShowDialog(); if (rotationForm.Save) { node.Tag = rotation; node.Text = rotation.Name; } } }
private void EditRule(Node node) { if (node.Tag is Rotation) { var rotation = (Rotation) node.Tag; var rotationForm = new RotationForm(rotation); rotationForm.Location = Location; rotationForm.ShowDialog(); if (rotationForm.Save) { node.Tag = rotation; node.Text = rotation.Name; } } }