From 703123f651bd41d35a5ca3b75cd14a9708d03ae7 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Thu, 8 May 2008 04:17:18 +0000 Subject: If no message catalog is installed for the current locale language, don't 2008-05-08 Tor Lillqvist * main.c (main) [Win32]: If no message catalog is installed for the current locale language, don't bother with the localisations provided by other things then either. Reset thread locale to "en-US" and C library locale to "C" to ensure that. svn path=/trunk/; revision=35479 --- shell/ChangeLog | 7 +++++++ shell/main.c | 11 +++++++++++ 2 files changed, 18 insertions(+) diff --git a/shell/ChangeLog b/shell/ChangeLog index fa452cccc8..4647ade3fc 100644 --- a/shell/ChangeLog +++ b/shell/ChangeLog @@ -1,3 +1,10 @@ +2008-05-08 Tor Lillqvist + + * main.c (main) [Win32]: If no message catalog is installed for + the current locale language, don't bother with the localisations + provided by other things then either. Reset thread locale to + "en-US" and C library locale to "C" to ensure that. + 2008-04-29 Akhil Laddha ** Fix for bug #529660 diff --git a/shell/main.c b/shell/main.c index 32bff688f6..7062ea9a6e 100644 --- a/shell/main.c +++ b/shell/main.c @@ -690,6 +690,17 @@ main (int argc, char **argv) GNOME_PARAM_HUMAN_READABLE_NAME, _("Evolution"), NULL); +#ifdef G_OS_WIN32 + if (strcmp (_(""), "") == 0) { + /* No message catalog installed for the current locale language, + * so don't bother with the localisations provided by other things then + * either. Reset thread locale to "en-US" and C library locale to "C". + */ + SetThreadLocale (MAKELCID (MAKELANGID (LANG_ENGLISH, SUBLANG_ENGLISH_US), + SORT_DEFAULT)); + setlocale (LC_ALL, "C"); + } +#endif if (start_online && start_offline) { fprintf (stderr, _("%s: --online and --offline cannot be used together.\n Use %s --help for more information.\n"), argv[0], argv[0]); -- cgit v1.2.3