mirror of https://github.com/GNOME/gimp.git
Don't use the compile-time paths to iso-codes on Windows. Instead assume
2008-02-12 Tor Lillqvist <tml@novell.com> * app/widgets/gimplanguagestore-parser.c (gimp_language_store_populate): Don't use the compile-time paths to iso-codes on Windows. Instead assume iso-codes is installed in the same location as GIMP. Make sure translated language names are in UTF-8 by calling bind_textdomain_codeset(). svn path=/trunk/; revision=24867
This commit is contained in:
parent
384835d7e2
commit
0d6c96b1a2
|
@ -1,3 +1,11 @@
|
|||
2008-02-12 Tor Lillqvist <tml@novell.com>
|
||||
|
||||
* app/widgets/gimplanguagestore-parser.c
|
||||
(gimp_language_store_populate): Don't use the compile-time paths
|
||||
to iso-codes on Windows. Instead assume iso-codes is installed in
|
||||
the same location as GIMP. Make sure translated language names are
|
||||
in UTF-8 by calling bind_textdomain_codeset().
|
||||
|
||||
2008-02-11 Sven Neumann <sven@gimp.org>
|
||||
|
||||
* app/widgets/Makefile.am
|
||||
|
|
|
@ -25,6 +25,8 @@
|
|||
|
||||
#include <gtk/gtk.h>
|
||||
|
||||
#include "libgimpbase/gimpenv.h"
|
||||
|
||||
#include "widgets-types.h"
|
||||
|
||||
#include "config/gimpxmlparser.h"
|
||||
|
@ -90,13 +92,24 @@ gimp_language_store_populate (GimpLanguageStore *store,
|
|||
g_return_val_if_fail (GIMP_IS_LANGUAGE_STORE (store), FALSE);
|
||||
g_return_val_if_fail (error == NULL || *error == NULL, FALSE);
|
||||
|
||||
#ifndef G_OS_WIN32
|
||||
bindtextdomain ("iso_639", ISO_CODES_LOCALEDIR);
|
||||
#else
|
||||
/* Assume iso-codes is installed in the same location as GIMP */
|
||||
bindtextdomain ("iso_639", gimp_locale_directory ());
|
||||
#endif
|
||||
|
||||
bind_textdomain_codeset ("iso_639", "UTF-8");
|
||||
|
||||
parser.store = g_object_ref (store);
|
||||
|
||||
xml_parser = gimp_xml_parser_new (&markup_parser, &parser);
|
||||
|
||||
#ifndef G_OS_WIN32
|
||||
filename = g_build_filename (ISO_CODES_LOCATION, "iso_639.xml", NULL);
|
||||
#else
|
||||
filename = g_build_filename (gimp_data_directory (), "..", "..", "xml", "iso-codes", "iso_639.xml", NULL);
|
||||
#endif
|
||||
|
||||
success = gimp_xml_parser_parse_file (xml_parser, filename, error);
|
||||
|
||||
|
|
Loading…
Reference in New Issue