Changeset 7290 for branches/RegressionBenchmarks/HeuristicLab.Analysis.Views/3.3/DataTableHistoryView.cs
- Timestamp:
- 01/08/12 19:13:14 (12 years ago)
- Location:
- branches/RegressionBenchmarks
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/RegressionBenchmarks
- Property svn:ignore
-
old new 18 18 bin 19 19 protoc.exe 20 *.user
-
- Property svn:mergeinfo changed
/trunk/sources merged: 7209,7214,7216-7230,7233-7239,7241,7243-7252,7254,7256-7261,7265-7266,7272-7275,7277,7280,7283
- Property svn:ignore
-
branches/RegressionBenchmarks/HeuristicLab.Analysis.Views/3.3/DataTableHistoryView.cs
r6628 r7290 1 1 #region License Information 2 2 /* HeuristicLab 3 * Copyright (C) 2002-201 1Heuristic and Evolutionary Algorithms Laboratory (HEAL)3 * Copyright (C) 2002-2012 Heuristic and Evolutionary Algorithms Laboratory (HEAL) 4 4 * 5 5 * This file is part of HeuristicLab. … … 38 38 if (current == null) return; 39 39 using (DataTableVisualPropertiesDialog dialog = new DataTableVisualPropertiesDialog(current)) { 40 if (dialog.ShowDialog() != DialogResult.OK) return; 41 Dictionary<string, bool> changeDisplayName = new Dictionary<string, bool>(); 42 foreach (DataRow row in current.Rows) { 43 var answer = MessageBox.Show("Change display name for series " + row.Name + " to " + row.VisualProperties.DisplayName + " for all frames?", "Confirm change", MessageBoxButtons.YesNoCancel, MessageBoxIcon.Question, MessageBoxDefaultButton.Button2); 44 if (answer == DialogResult.Cancel) return; 45 changeDisplayName[row.Name] = (answer == DialogResult.Yes); 46 } 40 if (dialog.ShowDialog(this) != DialogResult.OK) return; 41 HashSet<string> modifiedDisplayNames = new HashSet<string>(dialog.RowsWithModifiedDisplayNames); 47 42 foreach (DataTable dt in Content) { 48 43 if (current == dt) continue; … … 51 46 if (!dt.Rows.ContainsKey(row.Name)) continue; 52 47 string oldDisplayName = dt.Rows[row.Name].VisualProperties.DisplayName; 53 var props = (DataRowVisualProperties)row.VisualProperties.Clone();54 if (! changeDisplayName[row.Name]) props.DisplayName = oldDisplayName;55 dt.Rows[row.Name].VisualProperties = props;48 dt.Rows[row.Name].VisualProperties = (DataRowVisualProperties)row.VisualProperties.Clone(); 49 if (!modifiedDisplayNames.Contains(row.Name)) 50 dt.Rows[row.Name].VisualProperties.DisplayName = oldDisplayName; 56 51 } 57 52 } 58 53 } 59 54 } 60 61 55 } 62 56 }
Note: See TracChangeset
for help on using the changeset viewer.