Changeset 17420 for branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views
- Timestamp:
- 02/03/20 17:32:50 (5 years ago)
- Location:
- branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views/JsonItemArrayValueControl.Designer.cs
r17417 r17420 24 24 /// </summary> 25 25 private void InitializeComponent() { 26 components = new System.ComponentModel.Container(); 26 this.dataGridView = new System.Windows.Forms.DataGridView(); 27 this.numericRangeControl1 = new HeuristicLab.JsonInterface.OptimizerIntegration.NumericRangeControl(); 28 ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit(); 29 this.SuspendLayout(); 30 // 31 // dataGridView 32 // 33 this.dataGridView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 34 | System.Windows.Forms.AnchorStyles.Left) 35 | System.Windows.Forms.AnchorStyles.Right))); 36 this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize; 37 this.dataGridView.Location = new System.Drawing.Point(9, 75); 38 this.dataGridView.Name = "dataGridView"; 39 this.dataGridView.Size = new System.Drawing.Size(487, 171); 40 this.dataGridView.TabIndex = 13; 41 // 42 // numericRangeControl1 43 // 44 this.numericRangeControl1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) 45 | System.Windows.Forms.AnchorStyles.Right))); 46 this.numericRangeControl1.Location = new System.Drawing.Point(9, 252); 47 this.numericRangeControl1.Name = "numericRangeControl1"; 48 this.numericRangeControl1.Size = new System.Drawing.Size(487, 128); 49 this.numericRangeControl1.TabIndex = 14; 50 // 51 // JsonItemArrayValueControl 52 // 53 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 27 54 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 55 this.Controls.Add(this.numericRangeControl1); 56 this.Controls.Add(this.dataGridView); 57 this.Name = "JsonItemArrayValueControl"; 58 this.Size = new System.Drawing.Size(502, 386); 59 this.Controls.SetChildIndex(this.dataGridView, 0); 60 this.Controls.SetChildIndex(this.numericRangeControl1, 0); 61 ((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit(); 62 this.ResumeLayout(false); 63 this.PerformLayout(); 64 28 65 } 29 66 30 67 #endregion 68 69 private System.Windows.Forms.DataGridView dataGridView; 70 private NumericRangeControl numericRangeControl1; 31 71 } 32 72 } -
branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views/JsonItemArrayValueControl.cs
r17417 r17420 10 10 11 11 namespace HeuristicLab.JsonInterface.OptimizerIntegration { 12 public partial class JsonItemArrayValueControl : JsonItemBaseControl { 13 public JsonItemArrayValueControl(JsonItemVMBase vm) : base(vm) { 12 13 public class JsonItemIntArrayValueControl : JsonItemArrayValueControl { 14 public JsonItemIntArrayValueControl(IntArrayValueVM vm) : base(vm, vm.Value) { } 15 } 16 17 public class JsonItemDoubleArrayValueControl : JsonItemArrayValueControl { 18 public JsonItemDoubleArrayValueControl(DoubleArrayValueVM vm) : base(vm, vm.Value) { } 19 } 20 21 public abstract partial class JsonItemArrayValueControl : JsonItemBaseControl { 22 protected NumericRangeControl NumericRangeControl { get; set; } 23 24 public JsonItemArrayValueControl(JsonItemVMBase vm, object dataSource) : base(vm) { 14 25 InitializeComponent(); 26 dataGridView.DataSource = dataSource; 27 NumericRangeControl = numericRangeControl1; 28 29 NumericRangeControl.TBMinRange.DataBindings.Add("Text", VM, nameof(RangedValueBaseVM.MinRange)); 30 NumericRangeControl.TBMaxRange.DataBindings.Add("Text", VM, nameof(RangedValueBaseVM.MaxRange)); 31 NumericRangeControl.EnableMinRange.DataBindings.Add("Checked", VM, nameof(RangedValueBaseVM.EnableMinRange), 32 false, DataSourceUpdateMode.OnPropertyChanged); 33 NumericRangeControl.EnableMaxRange.DataBindings.Add("Checked", VM, nameof(RangedValueBaseVM.EnableMaxRange), 34 false, DataSourceUpdateMode.OnPropertyChanged); 15 35 } 16 36 } -
branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views/JsonItemRangeControl.cs
r17410 r17420 14 14 15 15 public JsonItemRangeControl(DoubleRangeVM vm) : base(vm) { 16 InitializeComponent(); 17 /* 18 this.isDouble = isDouble; 19 textBoxValueFrom.Text = ((Array)VM.Item.Value).GetValue(0).ToString(); 20 textBoxValueTo.Text = ((Array)VM.Item.Value).GetValue(1).ToString(); 21 textBoxValueFrom.Text = VM.Item.Range.First().ToString(); 22 textBoxValueTo.Text = VM.Item.Range.Last().ToString(); 23 */ 24 } 25 public JsonItemRangeControl(IntRangeVM vm) : base(vm) { 16 26 InitializeComponent(); 17 27 /* -
branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views/JsonItemValueControl.cs
r17417 r17420 16 16 #region Overriden Properties 17 17 protected override string ValuePropertyId => nameof(IntValueVM.Value); 18 protected override string MinRangePropertyId => nameof(IntValueVM.MinRange);19 protected override string MaxRangePropertyId => nameof(IntValueVM.MaxRange);20 protected override string EnableMinRangePropertyId => nameof(IntValueVM.EnableMinRange);21 protected override string EnableMaxRangePropertyId => nameof(IntValueVM.EnableMaxRange);22 18 #endregion 23 19 … … 32 28 #region Overriden Properties 33 29 protected override string ValuePropertyId => nameof(DoubleValueVM.Value); 34 protected override string MinRangePropertyId => nameof(DoubleValueVM.MinRange);35 protected override string MaxRangePropertyId => nameof(DoubleValueVM.MaxRange);36 protected override string EnableMinRangePropertyId => nameof(DoubleValueVM.EnableMinRange);37 protected override string EnableMaxRangePropertyId => nameof(DoubleValueVM.EnableMaxRange);38 30 #endregion 39 31 … … 52 44 #region Abstract Properties 53 45 protected abstract string ValuePropertyId { get; } 54 protected abstract string MinRangePropertyId { get; }55 protected abstract string MaxRangePropertyId { get; }56 protected abstract string EnableMinRangePropertyId { get; }57 protected abstract string EnableMaxRangePropertyId { get; }58 46 #endregion 59 47 … … 66 54 protected void Init() { 67 55 TBValue.DataBindings.Add("Text", base.VM, ValuePropertyId); 68 NumericRangeControl.TBMinRange.DataBindings.Add("Text", VM, MinRangePropertyId);69 NumericRangeControl.TBMaxRange.DataBindings.Add("Text", VM, MaxRangePropertyId);70 NumericRangeControl.EnableMinRange.DataBindings.Add("Checked", VM, EnableMinRangePropertyId,56 NumericRangeControl.TBMinRange.DataBindings.Add("Text", VM, nameof(RangedValueBaseVM.MinRange)); 57 NumericRangeControl.TBMaxRange.DataBindings.Add("Text", VM, nameof(RangedValueBaseVM.MaxRange)); 58 NumericRangeControl.EnableMinRange.DataBindings.Add("Checked", VM, nameof(RangedValueBaseVM.EnableMinRange), 71 59 false, DataSourceUpdateMode.OnPropertyChanged); 72 NumericRangeControl.EnableMaxRange.DataBindings.Add("Checked", VM, EnableMaxRangePropertyId,60 NumericRangeControl.EnableMaxRange.DataBindings.Add("Checked", VM, nameof(RangedValueBaseVM.EnableMaxRange), 73 61 false, DataSourceUpdateMode.OnPropertyChanged); 74 62 }
Note: See TracChangeset
for help on using the changeset viewer.