diff options
author | Eugenio Favalli <elvenprogrammer@gmail.com> | 2007-08-13 10:20:01 +0000 |
---|---|---|
committer | Eugenio Favalli <elvenprogrammer@gmail.com> | 2007-08-13 10:20:01 +0000 |
commit | d57bf8dbc6b035b2c0306fbc113a2880d9c50984 (patch) | |
tree | 66c2004acf84566c88d5640ec86aafe2e9481ba9 /src/main.cpp | |
parent | 81219329d4090dd2b1e3c37ae005f3c7795f4d08 (diff) | |
download | mana-d57bf8dbc6b035b2c0306fbc113a2880d9c50984.tar.gz mana-d57bf8dbc6b035b2c0306fbc113a2880d9c50984.tar.bz2 mana-d57bf8dbc6b035b2c0306fbc113a2880d9c50984.tar.xz mana-d57bf8dbc6b035b2c0306fbc113a2880d9c50984.zip |
Fixed internationalization support on Windows.
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp index 9a51f2e4..67086f9f 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -650,6 +650,8 @@ void initXML() xmlSetGenericErrorFunc(NULL, xmlNullLogger); } +extern "C" char const *_nl_locale_name_default(void); + /** Main */ int main(int argc, char *argv[]) { @@ -668,6 +670,9 @@ int main(int argc, char *argv[]) } #if ENABLE_NLS +#ifdef WIN32 + putenv(("LANG=" + std::string(_nl_locale_name_default())).c_str()); +#endif setlocale(LC_MESSAGES, ""); bindtextdomain("tmw", LOCALEDIR); bind_textdomain_codeset("tmw", "UTF-8"); |