Toolbox - rip out text feature since the box is too small to see it now

This commit is contained in:
adelikat 2013-12-22 03:21:32 +00:00
parent 928e14f110
commit 7a61b53fa1
2 changed files with 9 additions and 27 deletions

View File

@ -56,7 +56,7 @@
//
this.CloseBtn.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.CloseBtn.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.CloseBtn.Location = new System.Drawing.Point(152, 135);
this.CloseBtn.Location = new System.Drawing.Point(152, 110);
this.CloseBtn.Name = "CloseBtn";
this.CloseBtn.Size = new System.Drawing.Size(0, 23);
this.CloseBtn.TabIndex = 1;
@ -98,7 +98,7 @@
this.ToolBoxStrip.Location = new System.Drawing.Point(2, 2);
this.ToolBoxStrip.Name = "ToolBoxStrip";
this.ToolBoxStrip.Padding = new System.Windows.Forms.Padding(0);
this.ToolBoxStrip.Size = new System.Drawing.Size(137, 166);
this.ToolBoxStrip.Size = new System.Drawing.Size(137, 141);
this.ToolBoxStrip.Stretch = true;
this.ToolBoxStrip.TabIndex = 0;
this.ToolBoxStrip.TabStop = true;
@ -280,7 +280,7 @@
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.CancelButton = this.CloseBtn;
this.ClientSize = new System.Drawing.Size(140, 170);
this.ClientSize = new System.Drawing.Size(140, 145);
this.Controls.Add(this.CloseBtn);
this.Controls.Add(this.ToolBoxStrip);
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));

View File

@ -28,7 +28,6 @@ namespace BizHawk.Client.EmuHawk
SetTools();
ToolBoxItems.First().Select();
SetText();
SetSize();
ToolBoxItems.First().Select();
@ -68,15 +67,11 @@ namespace BizHawk.Client.EmuHawk
foreach (var button in ToolBoxItems)
{
var toolBtn = button as ToolStripButton;
toolBtn.Click += (o, e) => Close();
toolBtn.Paint += (o, e) =>
{
if (ToolBoxItems.Any(x => x.Selected))
{
SetText();
}
};
if (button.Visible)
{
var toolBtn = button as ToolStripButton;
toolBtn.Click += (o, e) => Close();
}
}
}
@ -86,19 +81,6 @@ namespace BizHawk.Client.EmuHawk
this.Height = 30 + (rows * 30);
}
private void SetText()
{
var items = ToolBoxItems.ToList();
if (items.Any(x => x.Selected))
{
Text = items.FirstOrDefault(x => x.Selected).ToolTipText;
}
else
{
Text = String.Empty;
}
}
/// <summary>
/// Provide LINQ capabilities to an outdated form collection
/// </summary>
@ -117,7 +99,7 @@ namespace BizHawk.Client.EmuHawk
private void CloseBtn_Enter(object sender, EventArgs e)
{
ToolBoxStrip.Focus();
//ToolBoxStrip.Focus();
}
#region Icon Clicks