private void FindDialog_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.Enter) { FindButton.PerformClick(); } }
private void FindTextBox_KeyUp(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.Enter) { FindButton.PerformClick(); FindTextBox.Focus(); FindTextBox.Select(0, FindTextBox.TextLength); } }
private void EditorTextBox_KeyDown(object sender, KeyEventArgs e) { AcceptButton = null; if (e.KeyCode != Keys.Enter) { return; } e.Handled = true; FindButton.PerformClick(); AcceptButton = CreateButton; }
private void FindTextBox_KeyPress(object sender, KeyPressEventArgs e) { e.Handled = true; if (e.KeyChar == '\r') { FindButton.PerformClick(); } else { e.Handled = false; } }
private void UserDialog_KeyDown(object sender, KeyEventArgs e) { if (e.KeyCode == Keys.Enter) { if (NameText.Focused) { FindButton.PerformClick(); } else if (list.Focused) { SelectAndClose(); } } }