From 47ff96778e8d84e6906f3ae5e2f5a61147461ea6 Mon Sep 17 00:00:00 2001 From: Suresh Chandrasekharan Date: Tue, 11 May 2004 00:42:19 +0000 Subject: Fixes bug #44196 addressbook table view uses ASCII sort 2004-05-10 Suresh Chandrasekharan Fixes bug #44196 addressbook table view uses ASCII sort svn path=/trunk/; revision=25851 --- addressbook/gui/widgets/e-addressbook-view.c | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'addressbook/gui/widgets/e-addressbook-view.c') diff --git a/addressbook/gui/widgets/e-addressbook-view.c b/addressbook/gui/widgets/e-addressbook-view.c index cf51653cd9..0c36039701 100644 --- a/addressbook/gui/widgets/e-addressbook-view.c +++ b/addressbook/gui/widgets/e-addressbook-view.c @@ -1638,8 +1638,18 @@ compare_subitems (const void *a, const void *b) { const ESearchBarSubitem *subitem_a = a; const ESearchBarSubitem *subitem_b = b; + char *collate_a, *collate_b; + int ret; - return strcoll (subitem_a->text, subitem_b->text); + collate_a = g_utf8_collate_key (subitem_a->text, -1); + collate_b = g_utf8_collate_key (subitem_b->text, -1); + + ret = strcmp (collate_a, collate_b); + + g_free (collate_a); + g_free (collate_b); + + return ret; } static void -- cgit