private void EditInterface() { if (this.listViewInterface.SelectedItems.Count < 1) { return; } MInterface mi = this.listViewInterface.SelectedItems[0].Tag as MInterface; FormMInterface frm = new FormMInterface(mi); if (frm.ShowDialog(this) != DialogResult.OK) { return; } RefreshInterfaceList(); }
private void AddInterface() { FormMInterface frm = new FormMInterface(null); if (frm.ShowDialog(this) != DialogResult.OK) { return; } MInterface mi = frm.MInterface; if (mi == null) { return; } Program.ConfigMgt.Config.Interfaces.Add(mi); RefreshInterfaceList(); }