Commit 0ce12615 authored by Yves Combe's avatar Yves Combe
Browse files

fix a bug in colors config combo_locales init.

parent dcacdf73
2005-08-18 Yves Combe,,, <yves@ycombe.net>
fix a bug in colors config combo_locales init.
* src/boards/colors.c: (colors_config_start):
* src/gcompris/board_config.c: (gcompris_combo_locales):
2005-08-18 Yves Combe <yves@ycombe.net>
gcompris_change_locale and gcompris_reset_locale are usefull fonction to change locale easily in boards. colors uses it, and pythontest.
......
......@@ -142,10 +142,12 @@ colors_config_start(GcomprisBoard *agcomprisBoard,
g_free(label);
/* init the combo to previously saved value */
GHashTable *config = gcompris_get_board_conf();
GHashTable *config = gcompris_get_conf( profile_conf, board_conf);
gchar *locale = g_hash_table_lookup( config, "locale");
if (!locale)
locale = "NULL";
locale = g_strdup("NULL");
/* Choose new value */
gcompris_combo_locales("locale", locale);
......
/* gcompris - board_config.c
*
* Time-stamp: <2005/08/18 00:53:22 yves>
* Time-stamp: <2005/08/18 01:42:58 yves>
*
* Copyright (C) 2001 Pascal Georges
*
......@@ -557,8 +557,7 @@ GtkComboBox *gcompris_combo_locales(gchar *key, gchar *init)
strings = g_list_prepend( strings, _("Default"));
if (init){
if (strcmp(init, "NULL")!=0)
init_index = g_list_position ( strings, g_list_find_custom ( strings,(gconstpointer) init, (GCompareFunc) my_strcmp));
init_index = g_list_position ( strings, g_list_find_custom ( strings,(gconstpointer) init, (GCompareFunc) my_strcmp));
}
if (init_index < 0)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment