Changeset 17439 for branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views
- Timestamp:
- 02/17/20 15:13:17 (5 years ago)
- Location:
- branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views/ExportJsonDialog.Designer.cs
r17435 r17439 30 30 this.groupBoxDetails = new System.Windows.Forms.GroupBox(); 31 31 this.panel = new System.Windows.Forms.Panel(); 32 this.jsonItemBindingSource = new System.Windows.Forms.BindingSource(this.components);33 32 this.resultItems = new System.Windows.Forms.CheckedListBox(); 34 33 this.groupBox2 = new System.Windows.Forms.GroupBox(); 35 34 this.groupBox3 = new System.Windows.Forms.GroupBox(); 36 this.splitContainer1 = new System.Windows.Forms.SplitContainer();37 35 this.splitContainer2 = new System.Windows.Forms.SplitContainer(); 36 this.tabControl1 = new System.Windows.Forms.TabControl(); 37 this.tabPage1 = new System.Windows.Forms.TabPage(); 38 this.tabPage2 = new System.Windows.Forms.TabPage(); 39 this.jsonItemBindingSource = new System.Windows.Forms.BindingSource(this.components); 38 40 this.groupBoxDetails.SuspendLayout(); 39 ((System.ComponentModel.ISupportInitialize)(this.jsonItemBindingSource)).BeginInit();40 41 this.groupBox2.SuspendLayout(); 41 42 this.groupBox3.SuspendLayout(); 42 ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();43 this.splitContainer1.Panel1.SuspendLayout();44 this.splitContainer1.Panel2.SuspendLayout();45 this.splitContainer1.SuspendLayout();46 43 ((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).BeginInit(); 47 44 this.splitContainer2.Panel1.SuspendLayout(); 48 45 this.splitContainer2.Panel2.SuspendLayout(); 49 46 this.splitContainer2.SuspendLayout(); 47 this.tabControl1.SuspendLayout(); 48 this.tabPage1.SuspendLayout(); 49 this.tabPage2.SuspendLayout(); 50 ((System.ComponentModel.ISupportInitialize)(this.jsonItemBindingSource)).BeginInit(); 50 51 this.SuspendLayout(); 51 52 // … … 60 61 this.exportButton.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left) 61 62 | System.Windows.Forms.AnchorStyles.Right))); 62 this.exportButton.Location = new System.Drawing.Point( 3, 570);63 this.exportButton.Location = new System.Drawing.Point(591, 578); 63 64 this.exportButton.Name = "exportButton"; 64 this.exportButton.Size = new System.Drawing.Size( 422, 29);65 this.exportButton.Size = new System.Drawing.Size(229, 29); 65 66 this.exportButton.TabIndex = 1; 66 67 this.exportButton.Text = "Export"; … … 73 74 | System.Windows.Forms.AnchorStyles.Left) 74 75 | System.Windows.Forms.AnchorStyles.Right))); 76 this.treeView.CheckBoxes = true; 75 77 this.treeView.Location = new System.Drawing.Point(6, 19); 76 78 this.treeView.Name = "treeView"; 77 this.treeView.Size = new System.Drawing.Size(35 3, 327);79 this.treeView.Size = new System.Drawing.Size(352, 497); 78 80 this.treeView.TabIndex = 3; 79 81 this.treeView.AfterSelect += new System.Windows.Forms.TreeViewEventHandler(this.treeView_AfterSelect); … … 85 87 | System.Windows.Forms.AnchorStyles.Right))); 86 88 this.groupBoxDetails.Controls.Add(this.panel); 87 this.groupBoxDetails.Location = new System.Drawing.Point(3, 3);89 this.groupBoxDetails.Location = new System.Drawing.Point(3, 0); 88 90 this.groupBoxDetails.Name = "groupBoxDetails"; 89 this.groupBoxDetails.Size = new System.Drawing.Size(4 22, 561);91 this.groupBoxDetails.Size = new System.Drawing.Size(415, 522); 90 92 this.groupBoxDetails.TabIndex = 4; 91 93 this.groupBoxDetails.TabStop = false; … … 100 102 this.panel.Location = new System.Drawing.Point(7, 20); 101 103 this.panel.Name = "panel"; 102 this.panel.Size = new System.Drawing.Size(40 9, 535);104 this.panel.Size = new System.Drawing.Size(402, 496); 103 105 this.panel.TabIndex = 0; 104 //105 // jsonItemBindingSource106 //107 this.jsonItemBindingSource.DataSource = typeof(HeuristicLab.JsonInterface.IJsonItem);108 106 // 109 107 // resultItems … … 115 113 this.resultItems.Location = new System.Drawing.Point(6, 19); 116 114 this.resultItems.Name = "resultItems"; 117 this.resultItems.Size = new System.Drawing.Size( 353, 199);115 this.resultItems.Size = new System.Drawing.Size(777, 499); 118 116 this.resultItems.TabIndex = 5; 119 117 // … … 124 122 | System.Windows.Forms.AnchorStyles.Right))); 125 123 this.groupBox2.Controls.Add(this.treeView); 126 this.groupBox2.Location = new System.Drawing.Point( 3, 3);124 this.groupBox2.Location = new System.Drawing.Point(0, 0); 127 125 this.groupBox2.Name = "groupBox2"; 128 this.groupBox2.Size = new System.Drawing.Size(36 5, 352);126 this.groupBox2.Size = new System.Drawing.Size(364, 522); 129 127 this.groupBox2.TabIndex = 6; 130 128 this.groupBox2.TabStop = false; … … 137 135 | System.Windows.Forms.AnchorStyles.Right))); 138 136 this.groupBox3.Controls.Add(this.resultItems); 139 this.groupBox3.Location = new System.Drawing.Point( 3, 3);137 this.groupBox3.Location = new System.Drawing.Point(6, 6); 140 138 this.groupBox3.Name = "groupBox3"; 141 this.groupBox3.Size = new System.Drawing.Size( 365, 231);139 this.groupBox3.Size = new System.Drawing.Size(789, 522); 142 140 this.groupBox3.TabIndex = 7; 143 141 this.groupBox3.TabStop = false; 144 142 this.groupBox3.Text = "Result Elements"; 145 143 // 146 // splitContainer1147 //148 this.splitContainer1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)149 | System.Windows.Forms.AnchorStyles.Left)150 | System.Windows.Forms.AnchorStyles.Right)));151 this.splitContainer1.Location = new System.Drawing.Point(3, 3);152 this.splitContainer1.Name = "splitContainer1";153 this.splitContainer1.Orientation = System.Windows.Forms.Orientation.Horizontal;154 //155 // splitContainer1.Panel1156 //157 this.splitContainer1.Panel1.Controls.Add(this.groupBox2);158 //159 // splitContainer1.Panel2160 //161 this.splitContainer1.Panel2.Controls.Add(this.groupBox3);162 this.splitContainer1.Size = new System.Drawing.Size(371, 599);163 this.splitContainer1.SplitterDistance = 358;164 this.splitContainer1.TabIndex = 8;165 //166 144 // splitContainer2 167 145 // … … 169 147 | System.Windows.Forms.AnchorStyles.Left) 170 148 | System.Windows.Forms.AnchorStyles.Right))); 171 this.splitContainer2.Location = new System.Drawing.Point( 12, 12);149 this.splitContainer2.Location = new System.Drawing.Point(6, 6); 172 150 this.splitContainer2.Name = "splitContainer2"; 173 151 // 174 152 // splitContainer2.Panel1 175 153 // 176 this.splitContainer2.Panel1.Controls.Add(this. splitContainer1);154 this.splitContainer2.Panel1.Controls.Add(this.groupBox2); 177 155 // 178 156 // splitContainer2.Panel2 179 157 // 180 158 this.splitContainer2.Panel2.Controls.Add(this.groupBoxDetails); 181 this.splitContainer2.Panel2.Controls.Add(this.exportButton); 182 this.splitContainer2.Size = new System.Drawing.Size(809, 605); 183 this.splitContainer2.SplitterDistance = 377; 159 this.splitContainer2.Size = new System.Drawing.Size(789, 522); 160 this.splitContainer2.SplitterDistance = 367; 184 161 this.splitContainer2.TabIndex = 9; 162 // 163 // tabControl1 164 // 165 this.tabControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 166 | System.Windows.Forms.AnchorStyles.Left) 167 | System.Windows.Forms.AnchorStyles.Right))); 168 this.tabControl1.Controls.Add(this.tabPage1); 169 this.tabControl1.Controls.Add(this.tabPage2); 170 this.tabControl1.Location = new System.Drawing.Point(12, 12); 171 this.tabControl1.Name = "tabControl1"; 172 this.tabControl1.SelectedIndex = 0; 173 this.tabControl1.Size = new System.Drawing.Size(809, 560); 174 this.tabControl1.TabIndex = 10; 175 // 176 // tabPage1 177 // 178 this.tabPage1.Controls.Add(this.splitContainer2); 179 this.tabPage1.Location = new System.Drawing.Point(4, 22); 180 this.tabPage1.Name = "tabPage1"; 181 this.tabPage1.Padding = new System.Windows.Forms.Padding(3); 182 this.tabPage1.Size = new System.Drawing.Size(801, 534); 183 this.tabPage1.TabIndex = 0; 184 this.tabPage1.Text = "Parameters"; 185 this.tabPage1.UseVisualStyleBackColor = true; 186 // 187 // tabPage2 188 // 189 this.tabPage2.Controls.Add(this.groupBox3); 190 this.tabPage2.Location = new System.Drawing.Point(4, 22); 191 this.tabPage2.Name = "tabPage2"; 192 this.tabPage2.Padding = new System.Windows.Forms.Padding(3); 193 this.tabPage2.Size = new System.Drawing.Size(801, 534); 194 this.tabPage2.TabIndex = 1; 195 this.tabPage2.Text = "Results"; 196 this.tabPage2.UseVisualStyleBackColor = true; 197 // 198 // jsonItemBindingSource 199 // 200 this.jsonItemBindingSource.DataSource = typeof(HeuristicLab.JsonInterface.IJsonItem); 185 201 // 186 202 // ExportJsonDialog … … 188 204 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 189 205 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 190 this.ClientSize = new System.Drawing.Size(833, 629); 191 this.Controls.Add(this.splitContainer2); 206 this.ClientSize = new System.Drawing.Size(833, 619); 207 this.Controls.Add(this.exportButton); 208 this.Controls.Add(this.tabControl1); 192 209 this.Name = "ExportJsonDialog"; 193 210 this.RightToLeft = System.Windows.Forms.RightToLeft.No; … … 195 212 this.Text = "Export Json"; 196 213 this.groupBoxDetails.ResumeLayout(false); 197 ((System.ComponentModel.ISupportInitialize)(this.jsonItemBindingSource)).EndInit();198 214 this.groupBox2.ResumeLayout(false); 199 215 this.groupBox3.ResumeLayout(false); 200 this.splitContainer1.Panel1.ResumeLayout(false);201 this.splitContainer1.Panel2.ResumeLayout(false);202 ((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit();203 this.splitContainer1.ResumeLayout(false);204 216 this.splitContainer2.Panel1.ResumeLayout(false); 205 217 this.splitContainer2.Panel2.ResumeLayout(false); 206 218 ((System.ComponentModel.ISupportInitialize)(this.splitContainer2)).EndInit(); 207 219 this.splitContainer2.ResumeLayout(false); 220 this.tabControl1.ResumeLayout(false); 221 this.tabPage1.ResumeLayout(false); 222 this.tabPage2.ResumeLayout(false); 223 ((System.ComponentModel.ISupportInitialize)(this.jsonItemBindingSource)).EndInit(); 208 224 this.ResumeLayout(false); 209 225 … … 222 238 private System.Windows.Forms.GroupBox groupBox2; 223 239 private System.Windows.Forms.GroupBox groupBox3; 224 private System.Windows.Forms.SplitContainer splitContainer1;225 240 private System.Windows.Forms.SplitContainer splitContainer2; 241 private System.Windows.Forms.TabControl tabControl1; 242 private System.Windows.Forms.TabPage tabPage1; 243 private System.Windows.Forms.TabPage tabPage2; 226 244 } 227 245 } -
branches/3026_IntegrationIntoSymSpace/HeuristicLab.JsonInterface.OptimizerIntegration/Views/ExportJsonDialog.cs
r17436 r17439 18 18 private static SaveFileDialog SaveFileDialog { get; set; } 19 19 private IDictionary<int, UserControl> Hash2Control { get; set; } = new Dictionary<int, UserControl>(); 20 private IDictionary<TreeNode, JsonItemVMBase> Node2VM { get; set; } = new Dictionary<TreeNode, JsonItemVMBase>(); 20 21 private IJsonItem Root { get; set; } 21 22 private IOptimizer Optimizer { get; set; } … … 38 39 Root = JsonItemConverter.Extract(Optimizer); 39 40 TreeNode parent = new TreeNode(Root.Name); 40 41 treeView.AfterCheck += TreeView_AfterCheck; 41 42 BuildTreeNode(parent, Root); 42 43 treeView.Nodes.Add(parent); … … 44 45 45 46 } 47 } 48 49 private void TreeView_AfterCheck(object sender, TreeViewEventArgs e) { 50 if (e.Action != TreeViewAction.Unknown) { 51 if (Node2VM.TryGetValue(e.Node, out JsonItemVMBase vm)) { 52 vm.Selected = e.Node.Checked; 53 } 54 } 46 55 } 47 56 … … 107 116 vm.TreeNode = node; 108 117 vm.TreeView = treeView; 118 Node2VM.Add(node, vm); 119 node.Checked = vm.Selected; 109 120 UserControl control = vm.GetControl(); 110 121 Hash2Control.Add(node.GetHashCode(), control);
Note: See TracChangeset
for help on using the changeset viewer.