From b41272695349bff112416423960467d94bd0f82f Mon Sep 17 00:00:00 2001 From: Jon Trowbridge Date: Sat, 27 Oct 2001 20:25:52 +0000 Subject: Doh! We should be sorting our contacts so that the most frequently used 2001-10-27 Jon Trowbridge * gui/component/select-names/e-select-names-completion.c (make_match): Doh! We should be sorting our contacts so that the most frequently used ones are at the top of the list, not the bottom. svn path=/trunk/; revision=14223 --- addressbook/gui/component/select-names/e-select-names-completion.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'addressbook/gui') diff --git a/addressbook/gui/component/select-names/e-select-names-completion.c b/addressbook/gui/component/select-names/e-select-names-completion.c index 9a6ce6871a..2e2cd03be1 100644 --- a/addressbook/gui/component/select-names/e-select-names-completion.c +++ b/addressbook/gui/component/select-names/e-select-names-completion.c @@ -110,7 +110,10 @@ make_match (EDestination *dest, const gchar *menu_form, double score) match = e_completion_match_new (e_destination_get_name (dest), menu_form, score); e_completion_match_set_text (match, e_destination_get_name (dest), menu_form); - match->sort_major = card ? floor (e_card_get_use_score (card)) : 0; + + /* Since we sort low to high, we negate so that larger use scores will come first */ + match->sort_major = card ? -floor (e_card_get_use_score (card)) : 0; + match->sort_minor = e_destination_get_email_num (dest); match->user_data = dest; -- cgit