analog controls: add ability to unbind buttons

This commit is contained in:
goyuken 2014-02-09 23:18:42 +00:00
parent 522f6549ad
commit d5bb0c9b4c
2 changed files with 19 additions and 0 deletions

View File

@ -38,6 +38,7 @@
this.trackBarDeadzone = new System.Windows.Forms.TrackBar();
this.labelDeadzone = new System.Windows.Forms.Label();
this.buttonFlip = new System.Windows.Forms.Button();
this.buttonUnbind = new System.Windows.Forms.Button();
((System.ComponentModel.ISupportInitialize)(this.trackBarSensitivity)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.trackBarDeadzone)).BeginInit();
this.SuspendLayout();
@ -123,10 +124,21 @@
this.buttonFlip.UseVisualStyleBackColor = true;
this.buttonFlip.Click += new System.EventHandler(this.buttonFlip_Click);
//
// buttonUnbind
//
this.buttonUnbind.Location = new System.Drawing.Point(3, 58);
this.buttonUnbind.Name = "buttonUnbind";
this.buttonUnbind.Size = new System.Drawing.Size(75, 23);
this.buttonUnbind.TabIndex = 8;
this.buttonUnbind.Text = "Unbind!";
this.buttonUnbind.UseVisualStyleBackColor = true;
this.buttonUnbind.Click += new System.EventHandler(this.buttonUnbind_Click);
//
// AnalogBindControl
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.Controls.Add(this.buttonUnbind);
this.Controls.Add(this.buttonFlip);
this.Controls.Add(this.labelDeadzone);
this.Controls.Add(this.trackBarDeadzone);
@ -155,5 +167,6 @@
private System.Windows.Forms.TrackBar trackBarDeadzone;
private System.Windows.Forms.Label labelDeadzone;
private System.Windows.Forms.Button buttonFlip;
private System.Windows.Forms.Button buttonUnbind;
}
}

View File

@ -83,5 +83,11 @@ namespace BizHawk.Client.EmuHawk
{
trackBarSensitivity.Value *= -1;
}
private void buttonUnbind_Click(object sender, EventArgs e)
{
Bind.Value = "";
textBox1.Text = "";
}
}
}