Changeset 5231 for branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3/ValueConfigurationViews
- Timestamp:
- 01/07/11 17:06:40 (14 years ago)
- Location:
- branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3/ValueConfigurationViews
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3/ValueConfigurationViews/ValueConfigurationCheckedItemList.cs
r5184 r5231 74 74 try { 75 75 IItem value = (IItem)objectSelectorDialog.Item.Clone(); 76 return new ValueConfiguration(value, value.GetType()); 76 if (value is NullValue) { 77 return new NullValueConfiguration(); 78 } else { 79 return new ValueConfiguration(value, value.GetType()); 80 } 77 81 } 78 82 catch (Exception ex) { -
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3/ValueConfigurationViews/ValueView.cs
r5207 r5231 46 46 47 47 private void setValueButton_Click(object sender, EventArgs e) { 48 var typesWithoutNullValue = Content.ValidTypes.Where(x => x != typeof(NullValue)); 49 var instances = typesWithoutNullValue.Select(x => (IItem)Activator.CreateInstance(x)); 50 var groupedInstances = instances.GroupBy(x => ApplicationManager.Manager.GetDeclaringPlugin(x.GetType()).Name); 48 //var typesWithoutNullValue = Content.ValidTypes.Where(x => x != typeof(NullValue)); 49 //var instances = typesWithoutNullValue.Select(x => (IItem)Activator.CreateInstance(x)); 50 //var groupedInstances = instances.GroupBy(x => ApplicationManager.Manager.GetDeclaringPlugin(x.GetType()).Name); 51 //var objectSelectorDialog = new ObjectSelectorDialog<IItem>(groupedInstances); 51 52 52 var objectSelectorDialog = new ObjectSelectorDialog<IItem>(groupedInstances); 53 var withoutNullValue = Content.ValidValues.Where(x => x != null && !(x is NullValue)); 54 var objectSelectorDialog = new ObjectSelectorDialog<IItem>(withoutNullValue.GroupBy(x => ApplicationManager.Manager.GetDeclaringPlugin(x.GetType()).Name)); 53 55 if (objectSelectorDialog.ShowDialog(this) == DialogResult.OK) { 54 56 try {
Note: See TracChangeset
for help on using the changeset viewer.