Changeset 10217
- Timestamp:
- 12/11/13 14:35:48 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/DataPreprocessing/HeuristicLab.Problems.DataAnalysis.Views/3.4/ProblemDataView.cs
r10134 r10217 30 30 using HeuristicLab.MainForm; 31 31 using HeuristicLab.MainForm.WindowsForms; 32 using HeuristicLab.Optimization.Views; 32 33 33 34 namespace HeuristicLab.Problems.DataAnalysis.Views { … … 103 104 104 105 private void DataPreprocessingButton_Click(object sender, EventArgs e) { 106 // IItem i = GetAlgorithmOrProblemContent(); 105 107 Type viewType = MainFormManager.GetViewTypes(this.Content.GetType(), true).FirstOrDefault(t => typeof(DataPreprocessingView).IsAssignableFrom(t)); 106 108 MainFormManager.MainForm.ShowContent(Content, viewType); 107 109 } 110 111 private IItem GetAlgorithmOrProblemContent() { 112 Control a = this; 113 IItem i = null; 114 do { 115 a = a.Parent; 116 } while (a != null && !(a is ProblemView)); 117 118 if (a is ProblemView) { 119 i = ((ProblemView)a).Content; 120 } 121 122 do { 123 a = a.Parent; 124 } while (a != null && !(a is AlgorithmView)); 125 126 if (a is AlgorithmView) { 127 i = ((AlgorithmView)a).Content; 128 } 129 130 return i; 131 132 //AlgorithmView algV = a as AlgorithmView; 133 //var clone = (IContent)algV.Content.Clone(new Cloner()); 134 //MainFormManager.MainForm.ShowContent(clone); 135 136 } 108 137 } 109 138 }
Note: See TracChangeset
for help on using the changeset viewer.