2 using System.Collections;
3 using System.Collections.Generic;
4 using System.ComponentModel;
8 using System.Windows.Forms;
10 namespace Sample_Environment_Control_Interface.Dialogs.Layout.Groups
15 private List<Group> localGroups =
new List<Group>();
16 private Boolean _changesMade =
false;
20 InitializeComponent();
29 for (
int i = 0; i < temp.GetLength(0); ++i)
31 localGroups.Add(temp[i]);
40 lstMembers.Items.Clear();
42 if (lstGroups.SelectedIndex != -1)
44 lstMembers.Items.AddRange(localGroups[lstGroups.SelectedIndex].VIMembers);
45 lstMembers.Items.AddRange(localGroups[lstGroups.SelectedIndex].ProgMembers);
51 lstGroups.Items.Clear();
52 lstMembers.Items.Clear();
55 if (localGroups != null)
57 for (
int i = 0; i < localGroups.Count; ++i)
59 lstGroups.Items.Add(localGroups[i].GroupName);
68 if (addgrp.ShowDialog() == DialogResult.OK)
70 localGroups.Add(addgrp.myGroup);
79 if (lstGroups.SelectedIndex != -1)
82 int index = lstGroups.SelectedIndex;
86 if (editgrp.ShowDialog() == DialogResult.OK)
88 localGroups.RemoveAt(index);
89 localGroups.Insert(index, editgrp.myGroup);
98 if (lstGroups.SelectedIndex != -1)
100 localGroups.RemoveAt(lstGroups.SelectedIndex);
108 SECI_GUI.CurrentLayout.OverWriteGroups(localGroups);
112 DialogResult = DialogResult.OK;
116 DialogResult = DialogResult.Cancel;
void lstGroups_SelectedIndexChanged(object sender, EventArgs e)
void btnEditGroup_Click(object sender, EventArgs e)
void btnAddGroup_Click(object sender, EventArgs e)
void btnOK_Click(object sender, EventArgs e)
void btnDelete_Click(object sender, EventArgs e)
static GUILayout CurrentLayout
void GroupVIs_Load(object sender, EventArgs e)