Changeset 13143
- Timestamp:
- 11/13/15 16:17:33 (9 years ago)
- Location:
- trunk/sources/HeuristicLab.Optimization.Views/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Optimization.Views/3.3/ExperimentTreeView.Designer.cs
r12012 r13143 51 51 this.CollapseToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 52 52 this.CollapseAllToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem(); 53 this.EditNodeLabelToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();54 53 this.toolTip = new System.Windows.Forms.ToolTip(this.components); 55 54 this.optimizersGroupBox.SuspendLayout(); … … 165 164 this.treeView.ImageIndex = 0; 166 165 this.treeView.ImageList = this.imageList; 167 this.treeView.LabelEdit = true;166 this.treeView.LabelEdit = false; 168 167 this.treeView.Location = new System.Drawing.Point(4, 34); 169 168 this.treeView.Name = "optimizerTreeView"; … … 220 219 // 221 220 this.contextMenuStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { 222 this.EditNodeLabelToolStripMenuItem,223 221 this.ExpandToolStripMenuItem, 224 222 this.ExpandAllToolStripMenuItem, … … 255 253 this.CollapseAllToolStripMenuItem.Text = "Collapse All"; 256 254 this.CollapseAllToolStripMenuItem.Click += new System.EventHandler(this.CollapseAllToolStripMenuItem_Click); 257 //258 // EditNodeLabelToolStripMenuItem259 //260 this.EditNodeLabelToolStripMenuItem.Name = "EditNodeLabelToolStripMenuItem";261 this.EditNodeLabelToolStripMenuItem.Size = new System.Drawing.Size(119, 22);262 this.EditNodeLabelToolStripMenuItem.Text = "Edit Name";263 this.EditNodeLabelToolStripMenuItem.Click += new System.EventHandler(this.EditNodeLabelToolStripMenuItem_Click);264 255 265 256 // … … 300 291 private System.Windows.Forms.ToolStripMenuItem CollapseToolStripMenuItem; 301 292 private System.Windows.Forms.ToolStripMenuItem CollapseAllToolStripMenuItem; 302 private System.Windows.Forms.ToolStripMenuItem EditNodeLabelToolStripMenuItem;303 293 304 294 } -
trunk/sources/HeuristicLab.Optimization.Views/3.3/ExperimentTreeView.cs
r12012 r13143 664 664 ExpandToolStripMenuItem.Enabled = ExpandToolStripMenuItem.Visible = !toolStripMenuNode.IsExpanded && toolStripMenuNode.Nodes.Count > 0; 665 665 CollapseToolStripMenuItem.Enabled = CollapseToolStripMenuItem.Visible = toolStripMenuNode.IsExpanded; 666 EditNodeLabelToolStripMenuItem.Enabled = EditNodeLabelToolStripMenuItem.Visible = !Locked && !ReadOnly && toolStripMenuNode.Tag != null && toolStripMenuNode.Tag is INamedItem && ((INamedItem)toolStripMenuNode.Tag).CanChangeName;667 666 } else { 668 667 ExpandToolStripMenuItem.Enabled = ExpandToolStripMenuItem.Visible = false; 669 668 CollapseToolStripMenuItem.Enabled = CollapseToolStripMenuItem.Visible = false; 670 EditNodeLabelToolStripMenuItem.Enabled = EditNodeLabelToolStripMenuItem.Visible = false;671 669 } 672 670 ExpandAllToolStripMenuItem.Enabled = ExpandAllToolStripMenuItem.Visible = !treeView.Nodes.OfType<TreeNode>().All(x => TreeNodeIsFullyExpanded(x)); … … 687 685 private void CollapseAllToolStripMenuItem_Click(object sender, EventArgs e) { 688 686 treeView.CollapseAll(); 689 }690 private void EditNodeLabelToolStripMenuItem_Click(object sender, EventArgs e) {691 if (toolStripMenuNode != null) {692 if (!toolStripMenuNode.IsEditing) toolStripMenuNode.BeginEdit();693 }694 687 } 695 688
Note: See TracChangeset
for help on using the changeset viewer.