Use canse insensitive search in language filter - thx rRobis :)

Fix #7479
This commit is contained in:
niksedk 2023-10-05 07:18:22 +02:00
parent 158310e0a6
commit a090311ce2

View File

@ -100,9 +100,9 @@ namespace Nikse.SubtitleEdit.Forms.Options
listView1.Items.Clear();
foreach (var x in _languageItems)
{
if (x.Name.Contains(textBoxSearch.Text) ||
x.Code.TwoLetterISOLanguageName == textBoxSearch.Text ||
x.Code.ThreeLetterISOLanguageName == textBoxSearch.Text)
if (x.Name.Contains(textBoxSearch.Text, StringComparison.OrdinalIgnoreCase) ||
x.Code.TwoLetterISOLanguageName.Equals(textBoxSearch.Text, StringComparison.OrdinalIgnoreCase) ||
x.Code.ThreeLetterISOLanguageName.Equals(textBoxSearch.Text, StringComparison.OrdinalIgnoreCase))
{
var listViewItem = new ListViewItem(x.ToString())
{