From 7728e7dbd26fd0140cf493a190c424105902fd7c Mon Sep 17 00:00:00 2001 From: Christopher James Lahey Date: Wed, 27 Jun 2001 00:22:02 +0000 Subject: Added category searching to the file backend. 2001-06-26 Christopher James Lahey * backend/pas/pas-backend-file.c (compare_category): Added category searching to the file backend. * gui/component/addressbook.c (addressbook_query_changed): Added category searching to the search bar. svn path=/trunk/; revision=10520 --- addressbook/gui/component/addressbook.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'addressbook/gui/component/addressbook.c') diff --git a/addressbook/gui/component/addressbook.c b/addressbook/gui/component/addressbook.c index bd51a3515e..cb52b6fd5d 100644 --- a/addressbook/gui/component/addressbook.c +++ b/addressbook/gui/component/addressbook.c @@ -547,12 +547,14 @@ enum { ESB_ANY, ESB_FULL_NAME, ESB_EMAIL, + ESB_CATEGORY, }; static ESearchBarItem addressbook_search_option_items[] = { { N_("Any field contains"), ESB_ANY }, { N_("Name contains"), ESB_FULL_NAME }, { N_("Email contains"), ESB_EMAIL }, + { N_("Category contains"), ESB_CATEGORY }, { NULL, -1 } }; @@ -581,6 +583,10 @@ addressbook_query_changed (ESearchBar *esb, AddressbookView *view) search_query = g_strdup_printf ("(contains \"email\" \"%s\")", search_word); break; + case ESB_CATEGORY: + search_query = g_strdup_printf ("(contains \"category\" \"%s\")", + search_word); + break; default: search_query = g_strdup ("(contains \"full_name\" \"\")"); break; -- cgit v1.2.3