Index: docs/reference/libedataserverui/libedataserverui-docs.sgml
===================================================================
--- docs/reference/libedataserverui/libedataserverui-docs.sgml	(revision 7815)
+++ docs/reference/libedataserverui/libedataserverui-docs.sgml	(working copy)
@@ -19,6 +19,7 @@
     <xi:include href="xml/e-name-selector-list.xml"/>
     <xi:include href="xml/e-name-selector-model.xml"/>
     <xi:include href="xml/e-passwords.xml"/>
+    <xi:include href="xml/e-source-combo-box.xml"/>
     <xi:include href="xml/e-source-option-menu.xml"/>
     <xi:include href="xml/e-source-selector.xml"/>
     <xi:include href="xml/e-source-selector-dialog.xml"/>
Index: docs/reference/libedataserverui/libedataserverui-sections.txt
===================================================================
--- docs/reference/libedataserverui/libedataserverui-sections.txt	(revision 7815)
+++ docs/reference/libedataserverui/libedataserverui-sections.txt	(working copy)
@@ -25,6 +25,29 @@ e_tree_model_generator_get_type
 </SECTION>
 
 <SECTION>
+<FILE>e-source-combo-box</FILE>
+<TITLE>ESourceComboBox</TITLE>
+ESourceComboBox
+e_source_combo_box_new
+e_source_combo_box_get_source_list
+e_source_combo_box_set_source_list
+e_source_combo_box_get_active
+e_source_combo_box_set_active
+e_source_combo_box_get_active_uid
+e_source_combo_box_set_active_uid
+<SUBSECTION Standard>
+E_SOURCE_COMBO_BOX
+E_IS_SOURCE_COMBO_BOX
+E_TYPE_SOURCE_COMBO_BOX
+E_SOURCE_COMBO_BOX_CLASS
+E_IS_SOURCE_COMBO_BOX_CLASS
+E_SOURCE_COMBO_BOX_GET_CLASS
+ESourceComboBoxClass
+<SUBSECTION Private>
+e_source_combo_box_get_type
+</SECTION>
+
+<SECTION>
 <FILE>e-source-option-menu</FILE>
 <TITLE>ESourceOptionMenu</TITLE>
 ESourceOptionMenu
Index: docs/reference/libedataserverui/libedataserverui.types
===================================================================
--- docs/reference/libedataserverui/libedataserverui.types	(revision 7815)
+++ docs/reference/libedataserverui/libedataserverui.types	(working copy)
@@ -6,6 +6,7 @@
 #include <libedataserverui/e-name-selector-entry.h>
 #include <libedataserverui/e-name-selector-list.h>
 #include <libedataserverui/e-name-selector-model.h>
+#include <libedataserverui/e-source-combo-box.h>
 #include <libedataserverui/e-source-option-menu.h>
 #include <libedataserverui/e-source-selector.h>
 #include <libedataserverui/e-source-selector-dialog.h>
@@ -19,6 +20,7 @@ e_name_selector_dialog_get_type
 e_name_selector_entry_get_type
 e_name_selector_list_get_type
 e_name_selector_model_get_type
+e_source_combo_box_get_type
 e_source_option_menu_get_type
 e_source_selector_get_type
 e_source_selector_dialog_get_type
Index: libedataserverui/e-source-option-menu.h
===================================================================
--- libedataserverui/e-source-option-menu.h	(revision 7815)
+++ libedataserverui/e-source-option-menu.h	(working copy)
@@ -23,6 +23,8 @@
 #ifndef _E_SOURCE_OPTION_MENU_H_
 #define _E_SOURCE_OPTION_MENU_H_
 
+#ifndef EDS_DISABLE_DEPRECATED
+
 #include <libedataserver/e-source-list.h>
 
 #include <gtk/gtkoptionmenu.h>
@@ -60,5 +62,6 @@ ESource *e_source_option_menu_peek_selec
 void     e_source_option_menu_select         (ESourceOptionMenu *menu,
 					      ESource           *source);
 
+#endif /* EDS_DISABLE_DEPRECATED */
 
 #endif /* _E_SOURCE_OPTION_MENU_H_ */
Index: libedataserverui/e-name-selector-dialog.c
===================================================================
--- libedataserverui/e-name-selector-dialog.c	(revision 7815)
+++ libedataserverui/e-name-selector-dialog.c	(working copy)
@@ -32,7 +32,7 @@
 #include <gtk/gtkscrolledwindow.h>
 #include <gtk/gtkstock.h>
 #include <glib/gi18n-lib.h>
-#include <libedataserverui/e-source-option-menu.h>
+#include <libedataserverui/e-source-combo-box.h>
 #include <libedataserverui/e-destination-store.h>
 #include <libedataserverui/e-contact-store.h>
 #include <libedataserverui/e-book-auth-util.h>
@@ -64,9 +64,8 @@ struct _ENameSelectorDialogPrivate
 	guint destination_index;
 };
 
-static ESource *find_first_source             (ESourceList *source_list);
 static void     search_changed                (ENameSelectorDialog *name_selector_dialog);
-static void     source_selected               (ENameSelectorDialog *name_selector_dialog, ESource *source);
+static void     source_changed                (ENameSelectorDialog *name_selector_dialog, ESourceComboBox *source_combo_box);
 static void     transfer_button_clicked       (ENameSelectorDialog *name_selector_dialog, GtkButton *transfer_button);
 static void     contact_selection_changed     (ENameSelectorDialog *name_selector_dialog);
 static void     setup_name_selector_model     (ENameSelectorDialog *name_selector_dialog);
@@ -106,33 +105,28 @@ e_name_selector_dialog_set_property (GOb
 {
 }
 
-/* FIXME: category_list should become part of ENameSelectorDialog structure */
-GList *category_list;
-
 static void
 e_name_selector_dialog_populate_categories (ENameSelectorDialog *name_selector_dialog)
 {
-	GtkWidget *category_option_menu;
-	GtkWidget *category_menu;
-	GList *l;
-	category_option_menu = glade_xml_get_widget (name_selector_dialog->gui, "optionmenu-category");
+	GtkWidget *combo_box;
+	GList *category_list, *iter;
 
-	/* Categories are already sorted */
-	category_list = e_categories_get_list () ;
-	category_list = g_list_prepend (category_list, _("Any Category"));
-
-	category_menu = gtk_menu_new ();
-	l = category_list;
-	while (l) {	
-		GtkWidget *item;
-		item = gtk_menu_item_new_with_label (l->data);
-		gtk_menu_shell_append (GTK_MENU_SHELL (category_menu), item);
-		l = l->next;
-	}
-	gtk_widget_show_all (category_menu);
-	gtk_option_menu_set_menu (GTK_OPTION_MENU (category_option_menu), category_menu);
-	
-	g_signal_connect_swapped (category_option_menu, "changed", G_CALLBACK (search_changed), name_selector_dialog);
+	/* "Any Category" is preloaded. */
+	combo_box = glade_xml_get_widget (
+		name_selector_dialog->gui, "combobox-category");
+	if (gtk_combo_box_get_active (GTK_COMBO_BOX (combo_box)) == -1)
+		gtk_combo_box_set_active (GTK_COMBO_BOX (combo_box), 0);
+
+	/* Categories are already sorted. */
+	category_list = e_categories_get_list ();
+	for (iter = category_list; iter != NULL; iter = iter->next)
+		gtk_combo_box_append_text (
+			GTK_COMBO_BOX (combo_box), iter->data);
+	g_list_free (category_list);
+
+	g_signal_connect_swapped (
+		combo_box, "changed",
+		G_CALLBACK (search_changed), name_selector_dialog);
 }
 
 static void
@@ -223,34 +217,26 @@ e_name_selector_dialog_init (ENameSelect
 
 	name_selector_dialog->name_selector_model = e_name_selector_model_new ();
 	name_selector_dialog->sections            = g_array_new (FALSE, FALSE, sizeof (Section));
-	name_selector_dialog->source_list         = source_list;
 
 	setup_name_selector_model (name_selector_dialog);
 
 	/* Create source menu */
 
-	widget = e_source_option_menu_new (name_selector_dialog->source_list);
-        
+	widget = e_source_combo_box_new (source_list);
+	g_signal_connect_swapped (
+		widget, "changed",
+		G_CALLBACK (source_changed), name_selector_dialog);
+	g_object_unref (source_list);
+ 
 	gconf_client = gconf_client_get_default();
 	uid = gconf_client_get_string (gconf_client, "/apps/evolution/addressbook/display/primary_addressbook",
 			NULL);
 	g_object_unref (gconf_client);
 	if (uid) {
-		ESource *source = e_source_list_peek_source_by_uid(name_selector_dialog->source_list, uid);
-		if (source) {
-			e_source_option_menu_select ((ESourceOptionMenu *)widget, source);
-			source_selected (name_selector_dialog, source);
-		}
-		else {
-			source_selected (name_selector_dialog, find_first_source (name_selector_dialog->source_list));
-		}
+		e_source_combo_box_set_active_uid (
+			E_SOURCE_COMBO_BOX (widget), uid);
 		g_free (uid);
 	}
-	else {
-		source_selected (name_selector_dialog, find_first_source (name_selector_dialog->source_list));
-	}
-
-	g_signal_connect_swapped (widget, "source_selected", G_CALLBACK (source_selected), name_selector_dialog);
 
 	label = glade_xml_get_widget (name_selector_dialog->gui, "AddressBookLabel");
 	gtk_label_set_mnemonic_widget (GTK_LABEL (label), widget);
@@ -308,9 +294,7 @@ e_name_selector_dialog_finalize (GObject
 	ENameSelectorDialog *name_selector_dialog = E_NAME_SELECTOR_DIALOG (object);
 
 	g_array_free (name_selector_dialog->sections, TRUE);
-	g_object_unref (name_selector_dialog->source_list);
 	g_object_unref (name_selector_dialog->button_size_group);
-	g_list_free (category_list);
 
 	if (G_OBJECT_CLASS (e_name_selector_dialog_parent_class)->finalize)
 		G_OBJECT_CLASS (e_name_selector_dialog_parent_class)->finalize (object);
@@ -384,26 +368,6 @@ sort_iter_to_contact_store_iter (ENameSe
 		*email_n = email_n_local;
 }
 
-static ESource *
-find_first_source (ESourceList *source_list)
-{
-	GSList *groups, *sources, *l, *m;
-			
-	groups = e_source_list_peek_groups (source_list);
-	for (l = groups; l; l = l->next) {
-		ESourceGroup *group = l->data;
-				
-		sources = e_source_group_peek_sources (group);
-		for (m = sources; m; m = m->next) {
-			ESource *source = m->data;
-
-			return source;
-		}				
-	}
-
-	return NULL;
-}
-
 static void
 add_destination (EDestinationStore *destination_store, EContact *contact, gint email_n)
 {
@@ -742,8 +706,13 @@ book_opened (EBook *book, EBookStatus st
 }
 
 static void
-source_selected (ENameSelectorDialog *name_selector_dialog, ESource *source)
+source_changed (ENameSelectorDialog *name_selector_dialog,
+                ESourceComboBox *source_combo_box)
 {
+	ESource *source;
+
+	source = e_source_combo_box_get_active (source_combo_box);
+
 	/* Remove any previous books being shown or loaded */
 	remove_books (name_selector_dialog);
 
@@ -761,49 +730,54 @@ search_changed (ENameSelectorDialog *nam
 {
 	EContactStore *contact_store;
 	EBookQuery    *book_query;
-	GtkWidget     *category_option_menu;
+	GtkWidget     *combo_box;
 	const gchar   *text;
-	gint 	      category_id;	
 	gchar         *text_escaped;
 	gchar         *query_string;
-	const gchar   *category;
+	gchar         *category;
 	gchar         *category_escaped;
 
-	category_option_menu = glade_xml_get_widget(name_selector_dialog->gui, "optionmenu-category");
-	category_id = gtk_option_menu_get_history (GTK_OPTION_MENU(category_option_menu));
-	category = g_list_nth_data (category_list, category_id);
-	if (!category)
-		return;
+	combo_box = glade_xml_get_widget (
+		name_selector_dialog->gui, "combobox-category");
+	if (gtk_combo_box_get_active (GTK_COMBO_BOX (combo_box)) == -1)
+		gtk_combo_box_set_active (GTK_COMBO_BOX (combo_box), 0);
+
+	category = gtk_combo_box_get_active_text (GTK_COMBO_BOX (combo_box));
 	category_escaped = escape_sexp_string (category);
 
 	text = gtk_entry_get_text (name_selector_dialog->search_entry);
 	text_escaped = escape_sexp_string (text);
 
-	if ( !strcmp (category, _("Any Category"))) {
-		query_string = g_strdup_printf ("(or (beginswith \"file_as\" %s) "
-						"    (beginswith \"full_name\" %s) "
-						"    (beginswith \"email\" %s) "
-						"    (beginswith \"nickname\" %s)))",
-						text_escaped, text_escaped, text_escaped, text_escaped);
-	}
-	else {
-		query_string = g_strdup_printf ("(and (is \"category_list\" %s) "
-						"(or (beginswith \"file_as\" %s) "
-						"    (beginswith \"full_name\" %s) "
-						"    (beginswith \"email\" %s) "
-						"    (beginswith \"nickname\" %s)))",
-						category_escaped,text_escaped, text_escaped, text_escaped, text_escaped);
-	}
+	if (!strcmp (category, _("Any Category")))
+		query_string = g_strdup_printf (
+			"(or (beginswith \"file_as\" %s) "
+			"    (beginswith \"full_name\" %s) "
+			"    (beginswith \"email\" %s) "
+			"    (beginswith \"nickname\" %s)))",
+			text_escaped, text_escaped,
+			text_escaped, text_escaped);
+	else
+		query_string = g_strdup_printf (
+			"(and (is \"category_list\" %s) "
+			"(or (beginswith \"file_as\" %s) "
+			"    (beginswith \"full_name\" %s) "
+			"    (beginswith \"email\" %s) "
+			"    (beginswith \"nickname\" %s)))",
+			category_escaped, text_escaped, text_escaped,
+			text_escaped, text_escaped);
 
 	book_query = e_book_query_from_string (query_string);
-	g_free (query_string);
-	g_free (text_escaped);
-	g_free (category_escaped);
 
-	contact_store = e_name_selector_model_peek_contact_store (name_selector_dialog->name_selector_model);
+	contact_store = e_name_selector_model_peek_contact_store (
+		name_selector_dialog->name_selector_model);
 	e_contact_store_set_query (contact_store, book_query);
 
 	e_book_query_unref (book_query);
+
+	g_free (query_string);
+	g_free (text_escaped);
+	g_free (category_escaped);
+	g_free (category);
 }
 
 static void
Index: libedataserverui/e-name-selector-entry.c
===================================================================
--- libedataserverui/e-name-selector-entry.c	(revision 7815)
+++ libedataserverui/e-name-selector-entry.c	(working copy)
@@ -2197,7 +2197,7 @@ populate_popup (ENameSelectorEntry *name
 		
 			if (len > 1) {
 				menu_item = gtk_radio_menu_item_new_with_label (group, email);
-				group = gtk_radio_menu_item_group (GTK_RADIO_MENU_ITEM (menu_item));
+				group = gtk_radio_menu_item_get_group (GTK_RADIO_MENU_ITEM (menu_item));
 				g_signal_connect (menu_item, "toggled", G_CALLBACK (destination_set_email), destination);
 			} else {
 				menu_item = gtk_menu_item_new_with_label (email);			
Index: libedataserverui/e-name-selector-dialog.h
===================================================================
--- libedataserverui/e-name-selector-dialog.h	(revision 7815)
+++ libedataserverui/e-name-selector-dialog.h	(working copy)
@@ -58,7 +58,7 @@ struct _ENameSelectorDialog {
 	/* Private */
 
 	EBook              *pending_book;
-	ESourceList        *source_list;
+	gpointer            placeholder;  /* for ABI compatibility */
 	ENameSelectorModel *name_selector_model;
 	GtkTreeModelSort   *contact_sort;
 
Index: libedataserverui/test-source-option-menu.c
===================================================================
--- libedataserverui/test-source-option-menu.c	(revision 7815)
+++ libedataserverui/test-source-option-menu.c	(working copy)
@@ -1,5 +1,5 @@
 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 8; tab-width: 8 -*- */
-/* test-source-option-menu.c - Test for ESourceOptionMenu.
+/* test-source-combo-box.c - Test for ESourceComboBox.
  *
  * Copyright (C) 2003 Novell, Inc.
  *
@@ -24,17 +24,17 @@
 #include <config.h>
 #endif
 
-
-#include "e-source-option-menu.h"
+#include "e-source-combo-box.h"
 
 #include <gtk/gtkwindow.h>
 #include <gtk/gtkmain.h>
 
 static void
-source_selected_callback (ESourceOptionMenu *menu,
-			  ESource *source,
-			  void *unused_data)
+source_changed_cb (ESourceComboBox *combo_box)
 {
+	ESource *source;
+
+	source = e_source_combo_box_get_active (combo_box);
 	g_print ("source selected: \"%s\"\n", e_source_peek_name (source));
 }
 
@@ -43,7 +43,7 @@ static int
 on_idle_create_widget (const char *gconf_path)
 {
 	GtkWidget *window;
-	GtkWidget *option_menu;
+	GtkWidget *combo_box;
 	ESourceList *source_list;
 	GConfClient *gconf_client;
 
@@ -51,10 +51,12 @@ on_idle_create_widget (const char *gconf
 	source_list = e_source_list_new_for_gconf (gconf_client, gconf_path);
 
 	window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
-	option_menu = e_source_option_menu_new (source_list);
-	g_signal_connect (option_menu, "source_selected", G_CALLBACK (source_selected_callback), NULL);
+	combo_box = e_source_combo_box_new (source_list);
+	g_signal_connect (
+		combo_box, "changed",
+		G_CALLBACK (source_changed_cb), NULL);
 
-	gtk_container_add (GTK_CONTAINER (window), option_menu);
+	gtk_container_add (GTK_CONTAINER (window), combo_box);
 	gtk_widget_show_all (window);
 
 	g_object_unref (gconf_client);
Index: libedataserverui/e-name-selector-dialog.glade
===================================================================
--- libedataserverui/e-name-selector-dialog.glade	(revision 7815)
+++ libedataserverui/e-name-selector-dialog.glade	(working copy)
@@ -118,7 +118,10 @@
 		  <property name="yalign">0.5</property>
 		  <property name="xpad">0</property>
 		  <property name="ypad">0</property>
-		  <property name="mnemonic_widget">optionmenu-category</property> 
+		  <property name="ellipsize">PANGO_ELLIPSIZE_NONE</property>
+		  <property name="width_chars">-1</property>
+		  <property name="single_line_mode">False</property>
+		  <property name="angle">0</property>
 		</widget>
 		<packing>
 		  <property name="left_attach">0</property>
@@ -127,23 +130,7 @@
 		  <property name="bottom_attach">2</property>
 		  <property name="x_options">fill</property>
 		  <property name="y_options"></property>
-	        </packing>
-	      </child>
-	
-	      <child>
-		<widget class="GtkOptionMenu" id="optionmenu-category">
-		  <property name="visible">True</property>
-		  <property name="can_focus">True</property>
-		  <property name="history">0</property>
-	        </widget>
-	        <packing>
-  	          <property name="left_attach">1</property>
-	     	  <property name="right_attach">2</property>
-	          <property name="top_attach">1</property>
-	          <property name="bottom_attach">2</property>
-	          <property name="x_options">fill</property>
-	          <property name="y_options">fill</property>
-	        </packing>
+		</packing>
 	      </child>
 
 	      <child>
@@ -229,6 +216,23 @@
 		  <property name="y_options">fill</property>
 		</packing>
 	      </child>
+
+	      <child>
+		<widget class="GtkComboBox" id="combobox-category">
+		  <property name="visible">True</property>
+		  <property name="items" translatable="yes">Any Category</property>
+		  <property name="add_tearoffs">False</property>
+		  <property name="focus_on_click">True</property>
+		</widget>
+		<packing>
+		  <property name="left_attach">1</property>
+		  <property name="right_attach">2</property>
+		  <property name="top_attach">1</property>
+		  <property name="bottom_attach">2</property>
+		  <property name="x_options">fill</property>
+		  <property name="y_options">fill</property>
+		</packing>
+	      </child>
 	    </widget>
 	    <packing>
 	      <property name="padding">0</property>
Index: libedataserverui/Makefile.am
===================================================================
--- libedataserverui/Makefile.am	(revision 7815)
+++ libedataserverui/Makefile.am	(working copy)
@@ -31,6 +31,7 @@ libedataserverui_1_2_la_SOURCES =	\
 	e-passwords.c			\
 	e-source-selector.c		\
 	e-source-selector-dialog.c	\
+	e-source-combo-box.c		\
 	e-source-option-menu.c		\
 	e-tree-model-generator.c
 
@@ -57,6 +58,7 @@ libedataserveruiinclude_HEADERS =	\
 	e-passwords.h			\
 	e-source-selector.h		\
 	e-source-selector-dialog.h	\
+	e-source-combo-box.h		\
 	e-source-option-menu.h		\
 	e-tree-model-generator.h
 
Index: libedataserverui/e-name-selector-list.c
===================================================================
--- libedataserverui/e-name-selector-list.c	(revision 7815)
+++ libedataserverui/e-name-selector-list.c	(working copy)
@@ -447,7 +447,7 @@ enl_tree_button_press_event (GtkWidget *
 		
 			if (len > 1) {
 				menu_item = gtk_radio_menu_item_new_with_label (group, email);
-				group = gtk_radio_menu_item_group (GTK_RADIO_MENU_ITEM (menu_item));
+				group = gtk_radio_menu_item_get_group (GTK_RADIO_MENU_ITEM (menu_item));
 				g_signal_connect (menu_item, "toggled", G_CALLBACK (destination_set_email), destination);
 			} else {
 				menu_item = gtk_menu_item_new_with_label (email);			
