aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2011-07-31 09:03:19 +0200
committerGiuseppe Bilotta <giuseppe.bilotta@gmail.com>2011-08-02 10:11:40 +0200
commit817180bd55dcadc81c0fc9753ba9bac573199dc9 (patch)
tree9ca5dfde783512bf669a65ff9d974aa14120879d
parent60bd878f0a0e0ad0c1d8f01aa9ba425e58cb2c2e (diff)
downloadminetest-817180bd55dcadc81c0fc9753ba9bac573199dc9.tar.gz
minetest-817180bd55dcadc81c0fc9753ba9bac573199dc9.tar.bz2
minetest-817180bd55dcadc81c0fc9753ba9bac573199dc9.zip
Introduce wgettext
All usages of gettext() are converted to wchars, so let's factor this into a single inline.
-rw-r--r--src/gettext.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gettext.h b/src/gettext.h
index ff3a0f8cb..f2cb8e471 100644
--- a/src/gettext.h
+++ b/src/gettext.h
@@ -30,6 +30,11 @@ inline wchar_t* chartowchar_t(const char *str)
return nstr;
}
+inline wchar_t* wgettext(const char *str)
+{
+ return chartowchar_t(gettext(str));
+}
+
inline void changeCtype(const char *l)
{
char *ret = NULL;