Mercurial > repos > IBDev-IBBoard.WarFoundry.GUI.WinForms
comparison FrmNewUnitFromTree.Designer.cs @ 210:694f23814ec2
Re #354: Single-button Add Unit
* Make the form translatable
* Update FrmArmyTree so it doesn't look out of place (ContextMenuStrip and update the icons)
* Add "change selection on right-click" code to solve calculation issues
* Hide categories that don't have entries (assume they're not relevant to that race)
Also:
* Clean up code and replace space indents with tabs
author | IBBoard <dev@ibboard.co.uk> |
---|---|
date | Sat, 20 Aug 2011 20:58:16 +0100 |
parents | a11faa64c333 |
children |
comparison
equal
deleted
inserted
replaced
209:a11faa64c333 | 210:694f23814ec2 |
---|---|
29 private void InitializeComponent() | 29 private void InitializeComponent() |
30 { | 30 { |
31 this.components = new System.ComponentModel.Container(); | 31 this.components = new System.ComponentModel.Container(); |
32 this.unitTypeTree = new System.Windows.Forms.TreeView(); | 32 this.unitTypeTree = new System.Windows.Forms.TreeView(); |
33 this.contextMenu = new System.Windows.Forms.ContextMenuStrip(this.components); | 33 this.contextMenu = new System.Windows.Forms.ContextMenuStrip(this.components); |
34 this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem(); | 34 this.addUnitMenuItem = new IBBoard.Windows.Forms.IBBToolStripMenuItem(); |
35 this.contextMenu.SuspendLayout(); | 35 this.contextMenu.SuspendLayout(); |
36 this.SuspendLayout(); | 36 this.SuspendLayout(); |
37 // | 37 // |
38 // unitTypeTree | 38 // unitTypeTree |
39 // | 39 // |
44 this.unitTypeTree.Location = new System.Drawing.Point(0, 0); | 44 this.unitTypeTree.Location = new System.Drawing.Point(0, 0); |
45 this.unitTypeTree.Name = "unitTypeTree"; | 45 this.unitTypeTree.Name = "unitTypeTree"; |
46 this.unitTypeTree.Size = new System.Drawing.Size(199, 287); | 46 this.unitTypeTree.Size = new System.Drawing.Size(199, 287); |
47 this.unitTypeTree.TabIndex = 0; | 47 this.unitTypeTree.TabIndex = 0; |
48 this.unitTypeTree.DoubleClick += new System.EventHandler(this.unitTypeTree_DoubleClick); | 48 this.unitTypeTree.DoubleClick += new System.EventHandler(this.unitTypeTree_DoubleClick); |
49 this.unitTypeTree.MouseDown += new System.Windows.Forms.MouseEventHandler(this.unitTypeTree_MouseDown); | |
49 // | 50 // |
50 // contextMenu | 51 // contextMenu |
51 // | 52 // |
52 this.contextMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { | 53 this.contextMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { |
53 this.toolStripMenuItem1}); | 54 this.addUnitMenuItem}); |
54 this.contextMenu.Name = "contextMenu"; | 55 this.contextMenu.Name = "contextMenu"; |
55 this.contextMenu.Size = new System.Drawing.Size(154, 26); | 56 this.contextMenu.Size = new System.Drawing.Size(163, 48); |
57 this.contextMenu.Opening += new System.ComponentModel.CancelEventHandler(this.contextMenu_Opening); | |
56 // | 58 // |
57 // toolStripMenuItem1 | 59 // addUnitMenuItem |
58 // | 60 // |
59 this.toolStripMenuItem1.Image = global::IBBoard.WarFoundry.GUI.WinForms.Properties.Resources.list_add; | 61 this.addUnitMenuItem.Image = global::IBBoard.WarFoundry.GUI.WinForms.Properties.Resources.list_add; |
60 this.toolStripMenuItem1.Name = "toolStripMenuItem1"; | 62 this.addUnitMenuItem.Name = "addUnitMenuItem"; |
61 this.toolStripMenuItem1.Size = new System.Drawing.Size(153, 22); | 63 this.addUnitMenuItem.Size = new System.Drawing.Size(162, 22); |
62 this.toolStripMenuItem1.Text = "Add Unit Type"; | 64 this.addUnitMenuItem.Text = "add unit of type"; |
63 this.toolStripMenuItem1.Click += new System.EventHandler(this.AddUnitClicked); | 65 this.addUnitMenuItem.Click += new System.EventHandler(this.AddUnitClicked); |
64 // | 66 // |
65 // FrmNewUnitFromTree | 67 // FrmNewUnitFromTree |
66 // | 68 // |
67 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); | 69 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); |
68 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; | 70 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; |
69 this.ClientSize = new System.Drawing.Size(199, 286); | 71 this.ClientSize = new System.Drawing.Size(199, 286); |
70 this.ControlBox = false; | 72 this.ControlBox = false; |
71 this.Controls.Add(this.unitTypeTree); | 73 this.Controls.Add(this.unitTypeTree); |
72 this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow; | 74 this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.SizableToolWindow; |
73 this.Name = "FrmNewUnitFromTree"; | 75 this.Name = "FrmNewUnitFromTree"; |
74 this.Text = "Available Unit Types"; | 76 this.Text = "available unit types"; |
75 this.contextMenu.ResumeLayout(false); | 77 this.contextMenu.ResumeLayout(false); |
76 this.ResumeLayout(false); | 78 this.ResumeLayout(false); |
77 | 79 |
78 } | 80 } |
79 | 81 |
80 #endregion | 82 #endregion |
81 | 83 |
82 private System.Windows.Forms.TreeView unitTypeTree; | 84 private System.Windows.Forms.TreeView unitTypeTree; |
83 private System.Windows.Forms.ContextMenuStrip contextMenu; | 85 private System.Windows.Forms.ContextMenuStrip contextMenu; |
84 private System.Windows.Forms.ToolStripMenuItem toolStripMenuItem1; | 86 private Windows.Forms.IBBToolStripMenuItem addUnitMenuItem; |
85 } | 87 } |
86 } | 88 } |