From 453d4dd80295dff91962830fe46d4a1feab6a683 Mon Sep 17 00:00:00 2001 From: niksedk Date: Thu, 12 Jun 2014 16:07:12 +0200 Subject: [PATCH] Allow more keys in GoToLine and Enter=OK --- src/Forms/GoToLine.cs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/Forms/GoToLine.cs b/src/Forms/GoToLine.cs index 22d3f221a..58b505e26 100644 --- a/src/Forms/GoToLine.cs +++ b/src/Forms/GoToLine.cs @@ -86,9 +86,13 @@ namespace Nikse.SubtitleEdit.Forms (e.KeyValue >= 96 && e.KeyValue <= 105)) { } - else if (e.KeyData == (Keys.Shift | Keys.Home) || e.KeyData == (Keys.Shift | Keys.End) || e.KeyData == (Keys.Control | Keys.A)) + else if (e.KeyData == (Keys.Shift | Keys.Home) || e.KeyData == (Keys.Shift | Keys.End)) { } + else if (e.KeyCode == Keys.Enter) + { + ButtonOkClick(null, null); + } else if (e.KeyData == (Keys.Control | Keys.V) && Clipboard.GetText(TextDataFormat.UnicodeText).Length > 0) { string p = Clipboard.GetText(TextDataFormat.UnicodeText); @@ -98,7 +102,7 @@ namespace Nikse.SubtitleEdit.Forms e.SuppressKeyPress = true; } } - else + else if (e.Modifiers != Keys.Control && e.Modifiers != Keys.Alt) { e.Handled = true; e.SuppressKeyPress = true;