Changeset 5653 for branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3/OptimizableView.cs
- Timestamp:
- 03/10/11 10:44:42 (14 years ago)
- Location:
- branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3
- Property svn:ignore
-
old new 3 3 HeuristicLab.Problems.MetaOptimization.Views-3.3.csproj.user 4 4 HeuristicLabProblemsMetaOptimizationViewsPlugin.cs 5 *.vs10x
-
- Property svn:ignore
-
branches/HeuristicLab.MetaOptimization/HeuristicLab.Problems.MetaOptimization.Views/3.3/OptimizableView.cs
r5087 r5653 1 1 using System; 2 using System.Collections.Generic;3 using System.ComponentModel;4 using System.Drawing;5 using System.Data;6 using System.Linq;7 using System.Text;8 2 using HeuristicLab.Core.Views; 3 using HeuristicLab.Data; 9 4 using HeuristicLab.MainForm; 10 using HeuristicLab.Parameters;11 using HeuristicLab.Core;12 using HeuristicLab.Data;13 5 14 6 namespace HeuristicLab.Problems.MetaOptimization.Views.ValueConfigurationViews { … … 47 39 if (Content.Optimize) { 48 40 this.viewHost.ViewType = null; 49 if (Content is IParameterConfiguration) { 41 42 var pc = Content as IParameterConfiguration; 43 var vc = Content as IValueConfiguration; 44 45 if (pc != null) { 50 46 this.viewHost.Content = ((IParameterConfiguration)Content).ValueConfigurations; 51 } else if (Content is IValueConfiguration) { 52 if (Content.ActualValue.ValueDataType == typeof(IntValue) || 47 } else if(vc != null) { 48 var rvc = Content as RangeValueConfiguration; 49 if (rvc != null) { 50 if (Content.ActualValue.ValueDataType == typeof(IntValue) || 53 51 Content.ActualValue.ValueDataType == typeof(DoubleValue) || 54 52 Content.ActualValue.ValueDataType == typeof(PercentValue)) { 55 this.viewHost.ViewsLabelVisible = true; 56 this.viewHost.Content = ((IValueConfiguration)Content).RangeConstraint; 57 } else if(Content.ActualValue.ValueDataType == typeof(BoolValue)) { 58 this.viewHost.Content = null; // no configuration required 59 } else { 53 this.viewHost.ViewsLabelVisible = true; 54 this.viewHost.Content = rvc.RangeConstraint; 55 } else if (Content.ActualValue.ValueDataType == typeof(BoolValue)) { 56 this.viewHost.Content = null; // no configuration required 57 } 58 } 59 60 var pvc = Content as ParameterizedValueConfiguration; 61 if (pvc != null) { 60 62 this.viewHost.ViewsLabelVisible = false; 61 this.viewHost.Content = ((IValueConfiguration)Content).ParameterConfigurations;63 this.viewHost.Content = pvc.ParameterConfigurations; 62 64 } 63 65 } else {
Note: See TracChangeset
for help on using the changeset viewer.