예제 #1
0
		private static void LoadControlPrefixInListViewItem(ControlPrefix controlPrefix, ListViewItem listViewItem) {
			listViewItem.SubItems.Clear();

			listViewItem.Text = controlPrefix.Prefix;
			listViewItem.SubItems.Add(controlPrefix.ControlTypeName);
			listViewItem.Tag = controlPrefix;
		}
예제 #2
0
		private void SaveControlPrefixFromControls(ControlPrefix aControlPrefix) {
			aControlPrefix.Prefix = txtControlPrefixPrefix.Text;
			aControlPrefix.ControlTypeName = txtControlPrefixTypeName.Text;
		}
예제 #3
0
     		private void btAddComponentPrefix_Click(object sender, System.EventArgs e) {
 			if (ControlPrefixIsValid()) {
 				ListViewItem _ListViewItem = new ListViewItem();
 				ControlPrefix _ControlPrefix = new ControlPrefix();
 
 				SaveControlPrefixFromControls(_ControlPrefix);
                 lvComponentPrefix.Items.Add(_ListViewItem);
 				LoadControlPrefixInListViewItem(_ControlPrefix, _ListViewItem);
 				lvComponentPrefix.SelectedItems.Clear();
 				_ListViewItem.Selected = true;
 			}
 
 			LoadControlPrefixInControl();
 		}