diff options
author | Andrei Karas <akaras@inbox.ru> | 2011-11-13 04:57:16 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2011-11-13 04:57:16 +0300 |
commit | 4d453108f45f9fb2ff4f5715cc1b3ddd63d36a80 (patch) | |
tree | c1edb8d8b368fdd43cd8639e6044b0f4e8dde70a /src/main.cpp | |
parent | ece00592ecd93f7a96db0ca82589d00846e2f938 (diff) | |
parent | d471e99fd38ac589a8a9e8e8677b9f577f0cc5c6 (diff) | |
download | mv-stripped1.1.11.12.tar.gz mv-stripped1.1.11.12.tar.bz2 mv-stripped1.1.11.12.tar.xz mv-stripped1.1.11.12.zip |
Merge branch 'master' into strippedstripped1.1.11.12
Conflicts:
data/fonts/mplus-1p-bold.ttf
data/fonts/mplus-1p-regular.ttf
src/guichan/basiccontainer.cpp
src/guichan/focushandler.cpp
src/guichan/graphics.cpp
src/guichan/gui.cpp
src/guichan/image.cpp
src/guichan/include/guichan/widgets/checkbox.hpp
src/guichan/include/guichan/widgets/dropdown.hpp
src/guichan/sdl/sdlgraphics.cpp
src/guichan/sdl/sdlimage.cpp
src/guichan/widget.cpp
src/guichan/widgets/dropdown.cpp
src/guichan/widgets/icon.cpp
src/guichan/widgets/imagebutton.cpp
src/guichan/widgets/listbox.cpp
src/guichan/widgets/scrollarea.cpp
src/guichan/widgets/tab.cpp
src/guichan/widgets/tabbedarea.cpp
src/guichan/widgets/textbox.cpp
src/guichan/widgets/window.cpp
Diffstat (limited to 'src/main.cpp')
-rw-r--r-- | src/main.cpp | 29 |
1 files changed, 3 insertions, 26 deletions
diff --git a/src/main.cpp b/src/main.cpp index 5eceee77b..b49b38300 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -107,12 +107,12 @@ static void parseOptions(int argc, char *argv[], Client::Options &options) { "chat-log-dir", required_argument, 0, 'L' }, { "screenshot-dir", required_argument, 0, 'i' }, { "safemode", no_argument, 0, 'm' }, - { 0, 0, 0, 0 } + { nullptr, 0, 0, 0 } }; while (optind < argc) { - int result = getopt_long(argc, argv, optstring, long_options, NULL); + int result = getopt_long(argc, argv, optstring, long_options, nullptr); if (result == -1) break; @@ -191,27 +191,6 @@ static void parseOptions(int argc, char *argv[], Client::Options &options) extern "C" char const *_nl_locale_name_default(void); #endif -static void initInternationalization() -{ -#if ENABLE_NLS -#ifdef WIN32 - putenv(("LANG=" + std::string(_nl_locale_name_default())).c_str()); - // mingw doesn't like LOCALEDIR to be defined for some reason - bindtextdomain("manaplus", "translations/"); -#else -#ifdef ENABLE_PORTABLE - bindtextdomain("manaplus", (std::string(PHYSFS_getBaseDir()) - + "../locale/").c_str()); -#else - bindtextdomain("manaplus", LOCALEDIR); -#endif -#endif - setlocale(LC_MESSAGES, ""); - bind_textdomain_codeset("manaplus", "UTF-8"); - textdomain("manaplus"); -#endif -} - static void xmlNullLogger(void *ctx A_UNUSED, const char *msg A_UNUSED, ...) { // Does nothing, that's the whole point of it @@ -225,7 +204,7 @@ static void initXML() LIBXML_TEST_VERSION; // Suppress libxml2 error messages - xmlSetGenericErrorFunc(NULL, xmlNullLogger); + xmlSetGenericErrorFunc(nullptr, xmlNullLogger); } @@ -260,8 +239,6 @@ int main(int argc, char *argv[]) return 1; } - initInternationalization(); - atexit((void(*)()) PHYSFS_deinit); initXML(); |