diff options
Diffstat (limited to 'addressbook/gui/contact-editor/e-contact-editor-fullname.c')
-rw-r--r-- | addressbook/gui/contact-editor/e-contact-editor-fullname.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/addressbook/gui/contact-editor/e-contact-editor-fullname.c b/addressbook/gui/contact-editor/e-contact-editor-fullname.c index cf97854956..0af0de3236 100644 --- a/addressbook/gui/contact-editor/e-contact-editor-fullname.c +++ b/addressbook/gui/contact-editor/e-contact-editor-fullname.c @@ -24,6 +24,7 @@ #include <libgnomeui/gnome-stock.h> #include <gal/widgets/e-unicode.h> #include "e-contact-editor-fullname.h" +#include <gtk/gtkcombo.h> static void e_contact_editor_fullname_init (EContactEditorFullname *card); static void e_contact_editor_fullname_class_init (EContactEditorFullnameClass *klass); @@ -161,9 +162,16 @@ e_contact_editor_fullname_set_arg (GtkObject *o, GtkArg *arg, guint arg_id) }; e_contact_editor_fullname->editable = GTK_VALUE_BOOL (*arg) ? TRUE : FALSE; for (i = 0; entry_names[i] != NULL; i ++) { - gtk_widget_set_sensitive (glade_xml_get_widget(e_contact_editor_fullname->gui, - entry_names[i]), - e_contact_editor_fullname->editable); + GtkWidget *w = glade_xml_get_widget(e_contact_editor_fullname->gui, entry_names[i]); + if (GTK_IS_ENTRY (w)) { + gtk_entry_set_editable (GTK_ENTRY (w), + e_contact_editor_fullname->editable); + } + else if (GTK_IS_COMBO (w)) { + gtk_entry_set_editable (GTK_ENTRY (GTK_COMBO (w)->entry), + e_contact_editor_fullname->editable); + gtk_widget_set_sensitive (GTK_COMBO (w)->button, e_contact_editor_fullname->editable); + } } break; } |