BizHawk/BizHawk.Client.EmuHawk/NameStateForm.cs

39 lines
706 B
C#
Raw Normal View History

2011-01-11 02:55:51 +00:00
using System;
using System.Windows.Forms;
namespace BizHawk.Client.EmuHawk
2011-01-11 02:55:51 +00:00
{
public partial class NameStateForm : Form
{
public string Result;
public bool OK;
2011-01-11 02:55:51 +00:00
public NameStateForm()
{
InitializeComponent();
AcceptButton = saveButton;
CancelButton = cancelButton;
}
2011-01-11 02:55:51 +00:00
private void cancelButton_Click(object sender, EventArgs e)
{
Close();
}
2011-01-11 02:55:51 +00:00
private void saveButton_Click(object sender, EventArgs e)
{
if (stateLabelTextBox.Text.Length != 0)
{
Result = stateLabelTextBox.Text;
OK = true;
Close();
}
}
2011-01-11 02:55:51 +00:00
private void NameStateForm_Shown(object sender, EventArgs e)
{
stateLabelTextBox.Focus();
}
}
2011-01-11 02:55:51 +00:00
}