- Timestamp:
- 02/12/10 15:37:36 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.GP/3.3/FunctionLibraryEditor.cs
r2729 r2788 57 57 initListView.Items.Clear(); 58 58 functionsListView.Clear(); 59 functionsComboBox.Items.Clear();60 59 foreach (IFunction fun in FunctionLibrary.Functions) { 61 60 functionsListView.Items.Add(CreateListViewItem(fun)); 62 functionsComboBox.Items.Add(fun);63 61 if (fun.Manipulator != null) { 64 62 mutationListView.Items.Add(CreateListViewItem(fun)); … … 134 132 data.SetData("DragSource", functionsListView); 135 133 DoDragDrop(data, DragDropEffects.Link); 136 }137 138 private void functionsComboBox_SelectedIndexChanged(object sender, EventArgs e) {139 if (functionsComboBox.SelectedItem != null) {140 IFunction selectedFun = (IFunction)functionsComboBox.SelectedItem;141 Control funView = (Control)selectedFun.CreateView();142 funView.Dock = DockStyle.Fill;143 functionDetailsPanel.Controls.Clear();144 functionDetailsPanel.Controls.Add(funView);145 }146 134 } 147 135 … … 320 308 } 321 309 #endregion 310 311 private void functionsListView_MouseUp(object sender, MouseEventArgs e) { 312 if (functionsListView.SelectedItems.Count > 0) { 313 IFunction selectedFun = (IFunction)functionsListView.SelectedItems[0].Tag; 314 Control funView = (Control)selectedFun.CreateView(); 315 funView.Dock = DockStyle.Fill; 316 functionDetailsPanel.Controls.Clear(); 317 functionDetailsPanel.Controls.Add(funView); 318 } 319 } 322 320 } 323 321 }
Note: See TracChangeset
for help on using the changeset viewer.