1
0
mirror of https://github.com/Radarr/Radarr.git synced 2024-11-20 01:42:35 +01:00

New: Add Macedonian and Slovenian languages

This commit is contained in:
Bogdan 2024-08-29 08:27:16 +03:00
parent 2700a6cf8a
commit 2d4846e5be
4 changed files with 18 additions and 4 deletions

View File

@ -57,7 +57,9 @@ public class LanguageFixture : CoreTest
new object[] { 42, Language.Estonian },
new object[] { 43, Language.Tamil },
new object[] { 44, Language.Indonesian },
new object[] { 45, Language.Telugu }
new object[] { 45, Language.Telugu },
new object[] { 46, Language.Macedonian },
new object[] { 47, Language.Slovenian }
};
public static object[] ToIntCases =
@ -109,7 +111,9 @@ public class LanguageFixture : CoreTest
new object[] { Language.Estonian, 42 },
new object[] { Language.Tamil, 43 },
new object[] { Language.Indonesian, 44 },
new object[] { Language.Telugu, 45 }
new object[] { Language.Telugu, 45 },
new object[] { Language.Macedonian, 46 },
new object[] { Language.Slovenian, 47 }
};
[Test]

View File

@ -53,6 +53,10 @@ public enum TMDbLanguageCodes
[FieldOption(Hint = "Bengali")]
bn,
[FieldOption(Hint = "Romanian")]
ro
ro,
[FieldOption(Hint = "Macedonian")]
mk,
[FieldOption(Hint = "Slovenian")]
sl
}
}

View File

@ -116,6 +116,8 @@ public override bool Equals(object obj)
public static Language Tamil => new Language(43, "Tamil");
public static Language Indonesian => new Language(44, "Indonesian");
public static Language Telugu => new Language(45, "Telugu");
public static Language Macedonian => new Language(46, "Macedonian");
public static Language Slovenian => new Language(47, "Slovenian");
public static Language Any => new Language(-1, "Any");
public static Language Original => new Language(-2, "Original");
@ -171,6 +173,8 @@ public static List<Language> All
Tamil,
Indonesian,
Telugu,
Macedonian,
Slovenian,
Any,
Original
};

View File

@ -54,7 +54,9 @@ public static class IsoLanguages
new IsoLanguage("et", "", "est", "Estonian", Language.Estonian),
new IsoLanguage("ta", "", "tam", "Tamil", Language.Tamil),
new IsoLanguage("id", "", "ind", "Indonesian", Language.Indonesian),
new IsoLanguage("te", "", "tel", "Telugu", Language.Telugu)
new IsoLanguage("te", "", "tel", "Telugu", Language.Telugu),
new IsoLanguage("mk", "", "mkd", "Macedonian", Language.Macedonian),
new IsoLanguage("sl", "", "slv", "Slovenian", Language.Slovenian),
};
private static readonly Dictionary<string, Language> AlternateIsoCodeMappings = new ()