aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-folder-view.c
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2003-10-22 02:28:34 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2003-10-22 02:28:34 +0800
commit0fb08f3ff81575a4749d851404233f34252dd2f2 (patch)
tree7e03befedc3a76fd104921dbbc616810d87333be /mail/em-folder-view.c
parent0e19f2c16de592607a341eb9974d31e4e47e02b5 (diff)
downloadgsoc2013-evolution-0fb08f3ff81575a4749d851404233f34252dd2f2.tar.gz
gsoc2013-evolution-0fb08f3ff81575a4749d851404233f34252dd2f2.tar.zst
gsoc2013-evolution-0fb08f3ff81575a4749d851404233f34252dd2f2.zip
Merge new-ui-branch to the trunk.
svn path=/trunk/; revision=22964
Diffstat (limited to 'mail/em-folder-view.c')
-rw-r--r--mail/em-folder-view.c40
1 files changed, 38 insertions, 2 deletions
diff --git a/mail/em-folder-view.c b/mail/em-folder-view.c
index 8099191b01..fac7d155d3 100644
--- a/mail/em-folder-view.c
+++ b/mail/em-folder-view.c
@@ -542,16 +542,52 @@ emfv_popup_undelete(GtkWidget *w, EMFolderView *emfv)
em_folder_view_mark_selected(emfv, CAMEL_MESSAGE_DELETED, 0);
}
+struct _move_data {
+ EMFolderView *emfv;
+ GPtrArray *uids;
+ int delete;
+};
+
+static void
+emfv_popup_move_cb(const char *uri, void *data)
+{
+ struct _move_data *d = data;
+
+ if (uri)
+ mail_transfer_messages(d->emfv->folder, d->uids, d->delete, uri, 0, NULL, NULL);
+ else
+ em_utils_uids_free(d->uids);
+
+ g_object_unref(d->emfv);
+ g_free(d);
+}
+
static void
emfv_popup_move(GtkWidget *w, EMFolderView *emfv)
{
- /* FIXME */
+ struct _move_data *d;
+
+ d = g_malloc(sizeof(*d));
+ d->emfv = emfv;
+ g_object_ref(emfv);
+ d->uids = message_list_get_selected(emfv->list);
+ d->delete = TRUE;
+
+ em_select_folder((GtkWidget *)emfv, _("Select folder"), NULL, NULL, emfv_popup_move_cb, d);
}
static void
emfv_popup_copy(GtkWidget *w, EMFolderView *emfv)
{
- /* FIXME */
+ struct _move_data *d;
+
+ d = g_malloc(sizeof(*d));
+ d->emfv = emfv;
+ g_object_ref(emfv);
+ d->uids = message_list_get_selected(emfv->list);
+ d->delete = FALSE;
+
+ em_select_folder((GtkWidget *)emfv, _("Select folder"), NULL, NULL, emfv_popup_move_cb, d);
}
static void