mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-10-28 06:52:35 +01:00
Work on shortcuts - thx OmrSi :)
This commit is contained in:
parent
f37477ac4a
commit
d10545e58e
@ -14895,7 +14895,9 @@ namespace Nikse.SubtitleEdit.Forms
|
||||
|
||||
// do not check for shortcuts if text is being entered and a textbox is focused
|
||||
var textBoxTypes = new List<string> { "AdvancedTextBox", "SimpleTextBox", "SETextBox", "TextBox", "RichTextBox" };
|
||||
if (textBoxTypes.Contains(typeName) && !Configuration.Settings.General.AllowLetterShortcutsInTextBox)
|
||||
if (textBoxTypes.Contains(typeName) &&
|
||||
((e.KeyCode >= Keys.A && e.KeyCode <= Keys.Z) || (e.KeyCode >= Keys.OemSemicolon && e.KeyCode <= Keys.OemBackslash) || e.KeyCode >= Keys.NumPad0 && e.KeyCode <= Keys.NumPad9 || e.KeyValue >= 48 && e.KeyValue <= 57) &&
|
||||
!Configuration.Settings.General.AllowLetterShortcutsInTextBox)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user