Changeset 3309
- Timestamp:
- 04/12/10 15:15:50 (15 years ago)
- Location:
- trunk/sources/HeuristicLab.Problems.DataAnalysis.Regression/3.3
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.DataAnalysis.Regression/3.3/HeuristicLab.Problems.DataAnalysis.Regression-3.3.csproj
r3294 r3309 125 125 <Name>HeuristicLab.Core-3.3</Name> 126 126 </ProjectReference> 127 <ProjectReference Include="..\..\HeuristicLab.Data.Views\3.3\HeuristicLab.Data.Views-3.3.csproj"> 128 <Project>{72104A0B-90E7-42F3-9ABE-9BBBADD4B943}</Project> 129 <Name>HeuristicLab.Data.Views-3.3</Name> 130 </ProjectReference> 127 131 <ProjectReference Include="..\..\HeuristicLab.Data\3.3\HeuristicLab.Data-3.3.csproj"> 128 132 <Project>{BBAB9DF5-5EF3-4BA8-ADE9-B36E82114937}</Project> -
trunk/sources/HeuristicLab.Problems.DataAnalysis.Regression/3.3/RegressionProblemData.cs
r3294 r3309 41 41 public Dataset Dataset { 42 42 get { return dataset; } 43 set { dataset = value; } 43 set { 44 if (dataset != value) { 45 if (value == null) throw new ArgumentNullException(); 46 else { 47 dataset = value; 48 OnDatasetChanged(EventArgs.Empty); 49 } 50 } 51 } 44 52 } 45 53 private StringValue targetVariable; … … 123 131 if (listeners != null) listeners(this, e); 124 132 } 133 134 public event EventHandler DatasetChanged; 135 protected virtual void OnDatasetChanged(EventArgs e) { 136 EventHandler handler = DatasetChanged; 137 if (handler != null) handler(this, e); 138 } 125 139 #endregion 126 140 -
trunk/sources/HeuristicLab.Problems.DataAnalysis.Regression/3.3/RegressionProblemDataView.Designer.cs
r3294 r3309 47 47 private void InitializeComponent() { 48 48 this.importButton = new System.Windows.Forms.Button(); 49 this.tabControl = new System.Windows.Forms.TabControl(); 50 this.parametersTabPage = new System.Windows.Forms.TabPage(); 51 this.parameterCollectionView = new HeuristicLab.Core.Views.ParameterCollectionView(); 49 this.datasetView = new HeuristicLab.Data.Views.StringConvertibleMatrixView(); 52 50 ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).BeginInit(); 53 this.tabControl.SuspendLayout();54 this.parametersTabPage.SuspendLayout();55 51 this.SuspendLayout(); 56 52 // … … 77 73 this.importButton.Click += new System.EventHandler(this.importButton_Click); 78 74 // 79 // tabControl75 // datasetView 80 76 // 81 this. tabControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)77 this.datasetView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 82 78 | System.Windows.Forms.AnchorStyles.Left) 83 79 | System.Windows.Forms.AnchorStyles.Right))); 84 this. tabControl.Controls.Add(this.parametersTabPage);85 this. tabControl.Location = new System.Drawing.Point(0, 52);86 this. tabControl.Name = "tabControl";87 this. tabControl.SelectedIndex = 0;88 this. tabControl.Size = new System.Drawing.Size(529, 341);89 this. tabControl.TabIndex = 4;80 this.datasetView.Caption = "StringConvertibleMatrix View"; 81 this.datasetView.Content = null; 82 this.datasetView.Location = new System.Drawing.Point(0, 52); 83 this.datasetView.Name = "datasetView"; 84 this.datasetView.Size = new System.Drawing.Size(526, 341); 85 this.datasetView.TabIndex = 6; 90 86 // 91 // parametersTabPage 92 // 93 this.parametersTabPage.Controls.Add(this.parameterCollectionView); 94 this.parametersTabPage.Location = new System.Drawing.Point(4, 22); 95 this.parametersTabPage.Name = "parametersTabPage"; 96 this.parametersTabPage.Padding = new System.Windows.Forms.Padding(3); 97 this.parametersTabPage.Size = new System.Drawing.Size(521, 315); 98 this.parametersTabPage.TabIndex = 0; 99 this.parametersTabPage.Text = "Parameters"; 100 this.parametersTabPage.UseVisualStyleBackColor = true; 101 // 102 // parameterCollectionView 103 // 104 this.parameterCollectionView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 105 | System.Windows.Forms.AnchorStyles.Left) 106 | System.Windows.Forms.AnchorStyles.Right))); 107 this.parameterCollectionView.Caption = "ParameterCollection"; 108 this.parameterCollectionView.Content = null; 109 this.parameterCollectionView.Location = new System.Drawing.Point(6, 6); 110 this.parameterCollectionView.Name = "parameterCollectionView"; 111 this.parameterCollectionView.Size = new System.Drawing.Size(509, 303); 112 this.parameterCollectionView.TabIndex = 0; 113 // 114 // RegressionProblemView 87 // RegressionProblemDataView 115 88 // 116 89 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 117 90 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 118 this.Controls.Add(this.tabControl);119 91 this.Controls.Add(this.importButton); 120 this.Name = "RegressionProblemView"; 92 this.Controls.Add(this.datasetView); 93 this.Name = "RegressionProblemDataView"; 121 94 this.Size = new System.Drawing.Size(529, 422); 95 this.Controls.SetChildIndex(this.datasetView, 0); 122 96 this.Controls.SetChildIndex(this.importButton, 0); 123 this.Controls.SetChildIndex(this.tabControl, 0);124 97 this.Controls.SetChildIndex(this.nameLabel, 0); 125 98 this.Controls.SetChildIndex(this.descriptionLabel, 0); … … 127 100 this.Controls.SetChildIndex(this.descriptionTextBox, 0); 128 101 ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).EndInit(); 129 this.tabControl.ResumeLayout(false);130 this.parametersTabPage.ResumeLayout(false);131 102 this.ResumeLayout(false); 132 103 this.PerformLayout(); … … 137 108 138 109 private System.Windows.Forms.Button importButton; 139 private System.Windows.Forms.TabControl tabControl; 140 private System.Windows.Forms.TabPage parametersTabPage; 141 private HeuristicLab.Core.Views.ParameterCollectionView parameterCollectionView; 110 private HeuristicLab.Data.Views.StringConvertibleMatrixView datasetView; 142 111 143 112 } -
trunk/sources/HeuristicLab.Problems.DataAnalysis.Regression/3.3/RegressionProblemDataView.cs
r3294 r3309 46 46 } 47 47 48 protected override void RegisterContentEvents() { 49 base.RegisterContentEvents(); 50 if (Content != null) 51 Content.DatasetChanged += new EventHandler(Content_DatasetChanged); 52 } 53 54 protected override void DeregisterContentEvents() { 55 base.DeregisterContentEvents(); 56 if(Content != null) 57 Content.DatasetChanged -= new EventHandler(Content_DatasetChanged); 58 } 59 60 private void Content_DatasetChanged(object sender, EventArgs e) { 61 this.datasetView.Content = this.Content.Dataset; 62 } 63 48 64 protected override void OnContentChanged() { 49 65 base.OnContentChanged(); 50 66 if (Content == null) { 51 parameterCollectionView.Content = null;52 parameterCollectionView.Enabled = false;53 67 importButton.Enabled = false; 54 68 } else {
Note: See TracChangeset
for help on using the changeset viewer.