make theme sorting case-insensitive (bug #481224)

2007-09-28  Jens Granseuer  <jensgr@gmx.net>

	* appearance-themes.c: (theme_store_sort_func): make theme sorting
	case-insensitive (bug #481224)

svn path=/trunk/; revision=8140
This commit is contained in:
Jens Granseuer 2007-09-28 17:01:41 +00:00 committed by Jens Granseuer
parent d5d94686bb
commit 597fac2a7c
2 changed files with 15 additions and 3 deletions

View file

@ -1,3 +1,8 @@
2007-09-28 Jens Granseuer <jensgr@gmx.net>
* appearance-themes.c: (theme_store_sort_func): make theme sorting
case-insensitive (bug #481224)
2007-09-23 Jens Granseuer <jensgr@gmx.net>
* gnome-wp-item.c: (gnome_wp_item_free), (gnome_wp_item_dup):

View file

@ -736,10 +736,17 @@ theme_store_sort_func (GtkTreeModel *model,
gtk_tree_model_get (model, b, COL_NAME, &b_name, COL_LABEL, &b_label, -1);
if (!strcmp (b_name, CUSTOM_THEME_NAME))
if (!strcmp (b_name, CUSTOM_THEME_NAME)) {
rc = 1;
else
rc = strcmp (a_label, b_label);
} else {
gchar *a_case, *b_case;
a_case = g_utf8_casefold (a_label, -1);
b_case = g_utf8_casefold (b_label, -1);
rc = g_utf8_collate (a_case, b_case);
g_free (a_case);
g_free (b_case);
}
g_free (b_name);
g_free (b_label);