mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-22 11:12:36 +01:00
Merge pull request #8086 from ivandrofly/issues/linux-lang-issue-8084
Fixes #8084
This commit is contained in:
commit
af80665222
@ -491,7 +491,13 @@ namespace Nikse.SubtitleEdit.Forms.Translate
|
|||||||
var installedLanguages = new List<string>();
|
var installedLanguages = new List<string>();
|
||||||
foreach (InputLanguage language in InputLanguage.InstalledInputLanguages)
|
foreach (InputLanguage language in InputLanguage.InstalledInputLanguages)
|
||||||
{
|
{
|
||||||
var iso639 = Iso639Dash2LanguageCode.GetTwoLetterCodeFromEnglishName(language.LayoutName);
|
var layoutName = language.LayoutName;
|
||||||
|
// related to https://github.com/SubtitleEdit/subtitleedit/issues/8084
|
||||||
|
if (string.IsNullOrEmpty(layoutName))
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
var iso639 = Iso639Dash2LanguageCode.GetTwoLetterCodeFromEnglishName(layoutName);
|
||||||
if (!string.IsNullOrEmpty(iso639) && !installedLanguages.Contains(iso639))
|
if (!string.IsNullOrEmpty(iso639) && !installedLanguages.Contains(iso639))
|
||||||
{
|
{
|
||||||
installedLanguages.Add(iso639.ToLowerInvariant());
|
installedLanguages.Add(iso639.ToLowerInvariant());
|
||||||
|
Loading…
Reference in New Issue
Block a user