- Timestamp:
- 11/20/10 02:44:45 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Analysis.Views/3.3/DataTableView.cs
r4849 r4870 67 67 foreach (DataRow row in Content.Rows) 68 68 DeregisterDataRowEvents(row); 69 Content.VisualPropertiesChanged -= new EventHandler(Content_VisualPropertiesChanged); 69 70 Content.Rows.ItemsAdded -= new CollectionItemsChangedEventHandler<DataRow>(Rows_ItemsAdded); 70 71 Content.Rows.ItemsRemoved -= new CollectionItemsChangedEventHandler<DataRow>(Rows_ItemsRemoved); … … 80 81 protected override void RegisterContentEvents() { 81 82 base.RegisterContentEvents(); 83 Content.VisualPropertiesChanged += new EventHandler(Content_VisualPropertiesChanged); 82 84 Content.Rows.ItemsAdded += new CollectionItemsChangedEventHandler<DataRow>(Rows_ItemsAdded); 83 85 Content.Rows.ItemsRemoved += new CollectionItemsChangedEventHandler<DataRow>(Rows_ItemsRemoved); … … 92 94 invisibleSeries.Clear(); 93 95 chart.Titles[0].Text = string.Empty; 96 chart.ChartAreas[0].AxisX.Title = string.Empty; 97 chart.ChartAreas[0].AxisY.Title = string.Empty; 98 chart.ChartAreas[0].AxisY2.Title = string.Empty; 94 99 chart.Series.Clear(); 95 100 if (Content != null) { … … 97 102 foreach (DataRow row in Content.Rows) 98 103 AddDataRow(row); 104 chart.ChartAreas[0].AxisX.Title = Content.VisualProperties.XAxisTitle; 105 chart.ChartAreas[0].AxisY.Title = Content.VisualProperties.YAxisTitle; 106 chart.ChartAreas[0].AxisY2.Title = Content.VisualProperties.SecondYAxisTitle; 99 107 } 100 108 } … … 188 196 } 189 197 } 198 private void Content_VisualPropertiesChanged(object sender, EventArgs e) { 199 if (InvokeRequired) 200 Invoke(new EventHandler(Content_VisualPropertiesChanged), sender, e); 201 else { 202 chart.ChartAreas[0].AxisX.Title = Content.VisualProperties.XAxisTitle; 203 chart.ChartAreas[0].AxisY.Title = Content.VisualProperties.YAxisTitle; 204 chart.ChartAreas[0].AxisY2.Title = Content.VisualProperties.SecondYAxisTitle; 205 } 206 } 190 207 private void Rows_ItemsAdded(object sender, CollectionItemsChangedEventArgs<DataRow> e) { 191 208 if (InvokeRequired)
Note: See TracChangeset
for help on using the changeset viewer.