# HG changeset patch # User alex # Date 1016637299 0 # Node ID 4afbe13150e6bc089831eb759325071ad6d35ac5 # Parent 9a2e8b32db2a1178c8621961177de9bf8eb5e11e splitted mp_msg_init and mp_msg_set_level and added i18n support to init diff -r 9a2e8b32db2a -r 4afbe13150e6 mp_msg.c --- a/mp_msg.c Wed Mar 20 14:56:26 2002 +0000 +++ b/mp_msg.c Wed Mar 20 15:14:59 2002 +0000 @@ -16,7 +16,21 @@ #if 1 -void mp_msg_init(int verbose){ +void mp_msg_init(){ +#ifdef USE_I18N + fprintf(stdout, "Using GNU internationalization\n"); + fprintf(stdout, "Original domain: %s\n", textdomain(NULL)); + fprintf(stdout, "Original dirname: %s\n", bindtextdomain(textdomain(NULL),NULL)); + setlocale(LC_ALL, ""); /* set from the environment variables */ + bindtextdomain("mplayer", PREFIX"/share/locale"); + textdomain("mplayer"); + fprintf(stdout, "Current domain: %s\n", textdomain(NULL)); + fprintf(stdout, "Current dirname: %s\n", bindtextdomain(textdomain(NULL),NULL)); +#endif + mp_msg_set_level(MSGL_STATUS); +} + +void mp_msg_set_level(int verbose){ int i; for(i=0;i +#include #define mp_gettext(String) gettext(String) #else #define mp_gettext(String) String