From eaa6cb0ddce9f623809792f7028876fdfaec2a37 Mon Sep 17 00:00:00 2001 From: Bond_009 Date: Fri, 25 Jan 2019 22:27:33 +0100 Subject: [PATCH] Fix a spelling mistake --- .../Localization/LocalizationManager.cs | 97 +++++++++---------- MediaBrowser.Api/LocalizationService.cs | 2 +- .../Globalization/ILocalizationManager.cs | 2 +- .../Globalization/LocalizationOption.cs | 14 +++ .../Globalization/LocalizatonOption.cs | 8 -- 5 files changed, 63 insertions(+), 60 deletions(-) create mode 100644 MediaBrowser.Model/Globalization/LocalizationOption.cs delete mode 100644 MediaBrowser.Model/Globalization/LocalizatonOption.cs diff --git a/Emby.Server.Implementations/Localization/LocalizationManager.cs b/Emby.Server.Implementations/Localization/LocalizationManager.cs index af05cd7d7..c408a47f6 100644 --- a/Emby.Server.Implementations/Localization/LocalizationManager.cs +++ b/Emby.Server.Implementations/Localization/LocalizationManager.cs @@ -502,58 +502,55 @@ namespace Emby.Server.Implementations.Localization return culture + ".json"; } - public LocalizatonOption[] GetLocalizationOptions() - { - return new LocalizatonOption[] + public LocalizationOption[] GetLocalizationOptions() + => new LocalizationOption[] { - new LocalizatonOption{ Name="Arabic", Value="ar"}, - new LocalizatonOption{ Name="Belarusian (Belarus)", Value="be-BY"}, - new LocalizatonOption{ Name="Bulgarian (Bulgaria)", Value="bg-BG"}, - new LocalizatonOption{ Name="Catalan", Value="ca"}, - new LocalizatonOption{ Name="Chinese Simplified", Value="zh-CN"}, - new LocalizatonOption{ Name="Chinese Traditional", Value="zh-TW"}, - new LocalizatonOption{ Name="Chinese Traditional (Hong Kong)", Value="zh-HK"}, - new LocalizatonOption{ Name="Croatian", Value="hr"}, - new LocalizatonOption{ Name="Czech", Value="cs"}, - new LocalizatonOption{ Name="Danish", Value="da"}, - new LocalizatonOption{ Name="Dutch", Value="nl"}, - new LocalizatonOption{ Name="English (United Kingdom)", Value="en-GB"}, - new LocalizatonOption{ Name="English (United States)", Value="en-US"}, - new LocalizatonOption{ Name="Finnish", Value="fi"}, - new LocalizatonOption{ Name="French", Value="fr"}, - new LocalizatonOption{ Name="French (Canada)", Value="fr-CA"}, - new LocalizatonOption{ Name="German", Value="de"}, - new LocalizatonOption{ Name="Greek", Value="el"}, - new LocalizatonOption{ Name="Hebrew", Value="he"}, - new LocalizatonOption{ Name="Hindi (India)", Value="hi-IN"}, - new LocalizatonOption{ Name="Hungarian", Value="hu"}, - new LocalizatonOption{ Name="Indonesian", Value="id"}, - new LocalizatonOption{ Name="Italian", Value="it"}, - new LocalizatonOption{ Name="Japanese", Value="ja"}, - new LocalizatonOption{ Name="Kazakh", Value="kk"}, - new LocalizatonOption{ Name="Korean", Value="ko"}, - new LocalizatonOption{ Name="Lithuanian", Value="lt-LT"}, - new LocalizatonOption{ Name="Malay", Value="ms"}, - new LocalizatonOption{ Name="Norwegian Bokmål", Value="nb"}, - new LocalizatonOption{ Name="Persian", Value="fa"}, - new LocalizatonOption{ Name="Polish", Value="pl"}, - new LocalizatonOption{ Name="Portuguese (Brazil)", Value="pt-BR"}, - new LocalizatonOption{ Name="Portuguese (Portugal)", Value="pt-PT"}, - new LocalizatonOption{ Name="Romanian", Value="ro"}, - new LocalizatonOption{ Name="Russian", Value="ru"}, - new LocalizatonOption{ Name="Slovak", Value="sk"}, - new LocalizatonOption{ Name="Slovenian (Slovenia)", Value="sl-SI"}, - new LocalizatonOption{ Name="Spanish", Value="es"}, - new LocalizatonOption{ Name="Spanish (Latin America)", Value="es-419"}, - new LocalizatonOption{ Name="Spanish (Mexico)", Value="es-MX"}, - new LocalizatonOption{ Name="Swedish", Value="sv"}, - new LocalizatonOption{ Name="Swiss German", Value="gsw"}, - new LocalizatonOption{ Name="Turkish", Value="tr"}, - new LocalizatonOption{ Name="Ukrainian", Value="uk"}, - new LocalizatonOption{ Name="Vietnamese", Value="vi"} - + new LocalizationOption("Arabic", "ar"), + new LocalizationOption("Belarusian (Belarus)", "be-BY"), + new LocalizationOption("Bulgarian (Bulgaria)", "bg-BG"), + new LocalizationOption("Catalan", "ca"), + new LocalizationOption("Chinese Simplified", "zh-CN"), + new LocalizationOption("Chinese Traditional", "zh-TW"), + new LocalizationOption("Chinese Traditional (Hong Kong)", "zh-HK"), + new LocalizationOption("Croatian", "hr"), + new LocalizationOption("Czech", "cs"), + new LocalizationOption("Danish", "da"), + new LocalizationOption("Dutch", "nl"), + new LocalizationOption("English (United Kingdom)", "en-GB"), + new LocalizationOption("English (United States)", "en-US"), + new LocalizationOption("Finnish", "fi"), + new LocalizationOption("French", "fr"), + new LocalizationOption("French (Canada)", "fr-CA"), + new LocalizationOption("German", "de"), + new LocalizationOption("Greek", "el"), + new LocalizationOption("Hebrew", "he"), + new LocalizationOption("Hindi (India)", "hi-IN"), + new LocalizationOption("Hungarian", "hu"), + new LocalizationOption("Indonesian", "id"), + new LocalizationOption("Italian", "it"), + new LocalizationOption("Japanese", "ja"), + new LocalizationOption("Kazakh", "kk"), + new LocalizationOption("Korean", "ko"), + new LocalizationOption("Lithuanian", "lt-LT"), + new LocalizationOption("Malay", "ms"), + new LocalizationOption("Norwegian Bokmål", "nb"), + new LocalizationOption("Persian", "fa"), + new LocalizationOption("Polish", "pl"), + new LocalizationOption("Portuguese (Brazil)", "pt-BR"), + new LocalizationOption("Portuguese (Portugal)", "pt-PT"), + new LocalizationOption("Romanian", "ro"), + new LocalizationOption("Russian", "ru"), + new LocalizationOption("Slovak", "sk"), + new LocalizationOption("Slovenian (Slovenia)", "sl-SI"), + new LocalizationOption("Spanish", "es"), + new LocalizationOption("Spanish (Latin America)", "es-419"), + new LocalizationOption("Spanish (Mexico)", "es-MX"), + new LocalizationOption("Swedish", "sv"), + new LocalizationOption("Swiss German", "gsw"), + new LocalizationOption("Turkish", "tr"), + new LocalizationOption("Ukrainian", "uk"), + new LocalizationOption("Vietnamese", "vi") }; - } } public interface ITextLocalizer diff --git a/MediaBrowser.Api/LocalizationService.cs b/MediaBrowser.Api/LocalizationService.cs index 0694de782..3b2e18852 100644 --- a/MediaBrowser.Api/LocalizationService.cs +++ b/MediaBrowser.Api/LocalizationService.cs @@ -33,7 +33,7 @@ namespace MediaBrowser.Api /// Class ParentalRatings /// [Route("/Localization/Options", "GET", Summary = "Gets localization options")] - public class GetLocalizationOptions : IReturn + public class GetLocalizationOptions : IReturn { } diff --git a/MediaBrowser.Model/Globalization/ILocalizationManager.cs b/MediaBrowser.Model/Globalization/ILocalizationManager.cs index a2531e504..05efb6681 100644 --- a/MediaBrowser.Model/Globalization/ILocalizationManager.cs +++ b/MediaBrowser.Model/Globalization/ILocalizationManager.cs @@ -49,7 +49,7 @@ namespace MediaBrowser.Model.Globalization /// Gets the localization options. /// /// IEnumerable{LocalizatonOption}. - LocalizatonOption[] GetLocalizationOptions(); + LocalizationOption[] GetLocalizationOptions(); string RemoveDiacritics(string text); diff --git a/MediaBrowser.Model/Globalization/LocalizationOption.cs b/MediaBrowser.Model/Globalization/LocalizationOption.cs new file mode 100644 index 000000000..c4c9a8919 --- /dev/null +++ b/MediaBrowser.Model/Globalization/LocalizationOption.cs @@ -0,0 +1,14 @@ +namespace MediaBrowser.Model.Globalization +{ + public class LocalizationOption + { + public LocalizationOption(string name, string value) + { + Name = name; + Value = value; + } + + public string Name { get; set; } + public string Value { get; set; } + } +} diff --git a/MediaBrowser.Model/Globalization/LocalizatonOption.cs b/MediaBrowser.Model/Globalization/LocalizatonOption.cs deleted file mode 100644 index 7fbc8135d..000000000 --- a/MediaBrowser.Model/Globalization/LocalizatonOption.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace MediaBrowser.Model.Globalization -{ - public class LocalizatonOption - { - public string Name { get; set; } - public string Value { get; set; } - } -}