diff options
Diffstat (limited to 'addressbook/gui/widgets')
-rw-r--r-- | addressbook/gui/widgets/eab-gui-util.c | 24 | ||||
-rw-r--r-- | addressbook/gui/widgets/eab-gui-util.h | 3 |
2 files changed, 27 insertions, 0 deletions
diff --git a/addressbook/gui/widgets/eab-gui-util.c b/addressbook/gui/widgets/eab-gui-util.c index 038c1454fc..2459b5c483 100644 --- a/addressbook/gui/widgets/eab-gui-util.c +++ b/addressbook/gui/widgets/eab-gui-util.c @@ -30,6 +30,7 @@ #include "eab-gui-util.h" #include "util/eab-book-util.h" #include "util/eab-destination.h" +#include "widgets/misc/e-image-chooser.h" #include "widgets/misc/e-source-selector.h" #include <gnome.h> @@ -859,3 +860,26 @@ eab_send_contact (EContact *contact, EABDisposition disposition) eab_send_contact_list (list, disposition); g_list_free (list); } + +GtkWidget * +eab_create_image_chooser_widget(gchar *name, + gchar *string1, gchar *string2, + gint int1, gint int2) +{ + char *filename; + GtkWidget *w = NULL; + if (string1) { + if (*string1 == '/') + filename = g_strdup(string1); + else + filename = g_build_filename (EVOLUTION_IMAGESDIR, string1, NULL); + + w = e_image_chooser_new (); + e_image_chooser_set_from_file (E_IMAGE_CHOOSER (w), filename); + + gtk_widget_show_all (w); + g_free (filename); + } + + return w; +} diff --git a/addressbook/gui/widgets/eab-gui-util.h b/addressbook/gui/widgets/eab-gui-util.h index 53700bed1f..5f96bc740c 100644 --- a/addressbook/gui/widgets/eab-gui-util.h +++ b/addressbook/gui/widgets/eab-gui-util.h @@ -65,6 +65,9 @@ void eab_send_contact (EContact *contact, void eab_send_contact_list (GList *contacts, EABDisposition disposition); +GtkWidget *eab_create_image_chooser_widget (gchar *name, gchar *string1, gchar *string2, gint int1, gint int2); + + ESource *eab_select_source (const gchar *title, const gchar *message, const gchar *select_uid, GtkWindow *parent); |