X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=webcit%2Fgettext.c;h=71ede4e0ad2083f58f66a6ae57307d78f6f34758;hb=898bab06ba7d6cf04a9b5e41bfcc6319ff3bb8de;hp=3639602e613aae2bc2ad1e95c3193bdca3fd77b4;hpb=307ff84a60b03889b9cd5ff84c29489177f9a39d;p=citadel.git diff --git a/webcit/gettext.c b/webcit/gettext.c index 3639602e6..71ede4e0a 100644 --- a/webcit/gettext.c +++ b/webcit/gettext.c @@ -14,7 +14,7 @@ #include "webserver.h" #define SEARCH_LANG 20 /* how many langs should we parse? */ -#ifdef ENABLE_NLS +#ifdef HAVE_USELOCALE /* actual supported locales */ const char *AvailLang[] = { "C", @@ -39,15 +39,14 @@ const char *AvailLang[] = { "kk_KK", "ro_RO", "sl_SL", + "tr_TR", "" }; const char **AvailLangLoaded; long nLocalesLoaded = 0; -#ifdef HAVE_USELOCALE locale_t *wc_locales; /* here we keep the parsed stuff */ -#endif /* Keep information about one locale */ typedef struct _lang_pref{ @@ -209,24 +208,10 @@ void httplang_to_locale(StrBuf *LocaleString, wcsession *sess) void tmplput_offer_languages(StrBuf *Target, WCTemplputParams *TP) { int i; -#ifndef HAVE_USELOCALE - char *Lang = getenv("LANG"); - - if (Lang == NULL) - Lang = "C"; -#endif - - if (nLocalesLoaded == 1) { - wc_printf("

%s

", AvailLangLoaded[0]); - return; - } wc_printf("