diff options
author | Chris Toshok <toshok@ximian.com> | 2004-01-31 06:52:39 +0800 |
---|---|---|
committer | Chris Toshok <toshok@src.gnome.org> | 2004-01-31 06:52:39 +0800 |
commit | de481df1b35a4dfc8b425082a84519e43f92c9e4 (patch) | |
tree | ac7af4c967ea08687eec0ab406b6129470d28e03 /addressbook/gui/widgets | |
parent | f06004a362ac6bb3bc3248653b5db266d554eb15 (diff) | |
download | gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.tar gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.tar.gz gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.tar.bz2 gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.tar.lz gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.tar.xz gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.tar.zst gsoc2013-evolution-de481df1b35a4dfc8b425082a84519e43f92c9e4.zip |
enable d&d drop photos.
2004-01-30 Chris Toshok <toshok@ximian.com>
* gui/contact-editor/e-contact-editor.c: enable d&d drop photos.
* gui/contact-editor/contact-editor.glade: use
eab_create_image_chooser_widget for the d&d'able image.
* gui/contact-list-editor/e-contact-list-editor.c: abstract out
all the d&d image support (it's now in
widgets/misc/e-image-chooser.[ch]).
* gui/contact-list-editor/contact-list-editor.glade: use
eab_create_image_chooser_widget for the d&d'able image.
* gui/widgets/eab-gui-util.c (eab_create_image_chooser_widget):
new function.
* gui/widgets/eab-gui-util.h: add prototype for
eab_create_image_chooser_widget.
svn path=/trunk/; revision=24553
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); |