aboutsummaryrefslogtreecommitdiffstats
path: root/addressbook/gui/widgets
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2010-02-09 03:52:18 +0800
committerMatthew Barnes <mbarnes@redhat.com>2010-02-09 07:57:24 +0800
commit67ce5f3b140525c2f5944270a9383616f9d67923 (patch)
tree167788f4efa12f87ac04c474598d61b5ca446464 /addressbook/gui/widgets
parent9cd1f937a26363aa108f3d2b36606b167597a2eb (diff)
downloadgsoc2013-evolution-67ce5f3b140525c2f5944270a9383616f9d67923.tar.gz
gsoc2013-evolution-67ce5f3b140525c2f5944270a9383616f9d67923.tar.zst
gsoc2013-evolution-67ce5f3b140525c2f5944270a9383616f9d67923.zip
Add DnD support to e-selection.c.
Avoid listing calendar and directory targets explicitly, so that e-selection.c contains the one and only master list. Still need to figure out how to centralize "text/x-source-vcard".
Diffstat (limited to 'addressbook/gui/widgets')
-rw-r--r--addressbook/gui/widgets/e-addressbook-selector.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/addressbook/gui/widgets/e-addressbook-selector.c b/addressbook/gui/widgets/e-addressbook-selector.c
index 21347e2529..d33680ac99 100644
--- a/addressbook/gui/widgets/e-addressbook-selector.c
+++ b/addressbook/gui/widgets/e-addressbook-selector.c
@@ -20,6 +20,8 @@
#include "e-addressbook-selector.h"
+#include <e-util/e-selection.h>
+
#include <eab-book-util.h>
#include <eab-contact-merging.h>
@@ -53,14 +55,8 @@ enum {
PROP_CURRENT_VIEW
};
-enum {
- DND_TARGET_TYPE_VCARD,
- DND_TARGET_TYPE_SOURCE_VCARD
-};
-
static GtkTargetEntry drag_types[] = {
- { (gchar *) "text/x-vcard", 0, DND_TARGET_TYPE_VCARD },
- { (gchar *) "text/x-source-vcard", 0, DND_TARGET_TYPE_SOURCE_VCARD }
+ { (gchar *) "text/x-source-vcard", 0, 0 }
};
static gpointer parent_class;
@@ -367,6 +363,8 @@ addressbook_selector_init (EAddressbookSelector *selector)
GTK_WIDGET (selector), GTK_DEST_DEFAULT_ALL,
drag_types, G_N_ELEMENTS (drag_types),
GDK_ACTION_COPY | GDK_ACTION_MOVE);
+
+ e_drag_dest_add_directory_targets (GTK_WIDGET (selector));
}
GType