summaryrefslogtreecommitdiffstats
path: root/patches/xmms/source/rcc_langs.h
diff options
context:
space:
mode:
Diffstat (limited to 'patches/xmms/source/rcc_langs.h')
-rw-r--r--patches/xmms/source/rcc_langs.h120
1 files changed, 120 insertions, 0 deletions
diff --git a/patches/xmms/source/rcc_langs.h b/patches/xmms/source/rcc_langs.h
new file mode 100644
index 0000000..70abebf
--- /dev/null
+++ b/patches/xmms/source/rcc_langs.h
@@ -0,0 +1,120 @@
+typedef struct xmms_rcc_langs_t {
+ const char *sn;
+ const char *name;
+} xmms_rcc_langs;
+
+static const char *default_lang = "XXX";
+static xmms_rcc_langs langs[] = {
+ { "aa", "aar" },
+ { "ab", "abk" },
+ { "af", "afr" },
+ { "ak", "aka" },
+ { "am", "amh" },
+ { "ar", "ara" },
+ { "an", "arg" },
+ { "as", "asm" },
+ { "av", "ava" },
+ { "ae", "ave" },
+ { "ay", "aym" },
+ { "ba", "bak" },
+ { "bm", "bam" },
+ { "bn", "ben" },
+ { "bh", "bih" },
+ { "bi", "bis" },
+ { "bs", "bos" },
+ { "br", "bre" },
+ { "bg", "bul" },
+ { "ch", "cha" },
+ { "cv", "chv" },
+ { "kw", "cor" },
+ { "co", "cos" },
+ { "cr", "cre" },
+ { "dv", "div" },
+ { "dz", "dzo" },
+ { "en", "eng" },
+ { "et", "est" },
+ { "fj", "fij" },
+ { "fi", "fin" },
+ { "fy", "fry" },
+ { "ff", "ful" },
+ { "ig", "ibo" },
+ { "io", "ido" },
+ { "iu", "iku" },
+ { "ie", "ile" },
+ { "ik", "ipk" },
+ { "it", "ita" },
+ { "jv", "jav" },
+ { "ja", "jpn" },
+ { "kn", "kan" },
+ { "ks", "kas" },
+ { "kr", "kau" },
+ { "kk", "kaz" },
+ { "km", "khm" },
+ { "rw", "kin" },
+ { "ky", "kir" },
+ { "kv", "kom" },
+ { "kg", "kon" },
+ { "ku", "kur" },
+ { "lo", "lao" },
+ { "la", "lat" },
+ { "lv", "lav" },
+ { "ln", "lin" },
+ { "lt", "lit" },
+ { "lg", "lug" },
+ { "mh", "mah" },
+ { "ml", "mal" },
+ { "mr", "mar" },
+ { "mg", "mlg" },
+ { "mt", "mlt" },
+ { "mo", "mol" },
+ { "mn", "mon" },
+ { "na", "nau" },
+ { "ng", "ndo" },
+ { "oj", "oji" },
+ { "or", "ori" },
+ { "om", "orm" },
+ { "pi", "pli" },
+ { "ps", "pus" },
+ { "qu", "que" },
+ { "rn", "run" },
+ { "ru", "rus" },
+ { "sg", "sag" },
+ { "sa", "san" },
+ { "sn", "sna" },
+ { "sd", "snd" },
+ { "so", "som" },
+ { "sc", "srd" },
+ { "ss", "ssw" },
+ { "sw", "swa" },
+ { "ty", "tah" },
+ { "ta", "tam" },
+ { "tg", "tgk" },
+ { "tl", "tgl" },
+ { "ti", "tir" },
+ { "tn", "tsn" },
+ { "ts", "tso" },
+ { "tr", "tur" },
+ { "tw", "twi" },
+ { "uk", "ukr" },
+ { "ur", "urd" },
+ { "uz", "uzb" },
+ { "vi", "vie" },
+ { "wa", "wln" },
+ { "wo", "wol" },
+ { "xh", "xho" },
+ { "yi", "yid" },
+ { "yo", "yor" },
+ { "zu", "zul" },
+ { NULL, NULL }
+};
+
+const char *xmms_rcc_get_639_2_name(const char *sn) {
+ unsigned int i;
+
+ if ((!sn)||(!strcasecmp(sn, "off"))) return default_lang;
+
+ for (i=0; langs[i].sn; i++)
+ if (!strcasecmp(sn, langs[i].sn)) return langs[i].name;
+
+ return default_lang;
+}