aboutsummaryrefslogtreecommitdiffstats
path: root/mail/component-factory.c
diff options
context:
space:
mode:
authorJeffrey Stedfast <fejj@ximian.com>2001-11-10 03:36:03 +0800
committerJeffrey Stedfast <fejj@src.gnome.org>2001-11-10 03:36:03 +0800
commit056f54ee2814a37f40294c45fc78e49bfb40c358 (patch)
treedf663422f31f329fb5213f8d75cf4482d3598fc8 /mail/component-factory.c
parentf47013c7c1b957703016880140f2fff4c1a9583c (diff)
downloadgsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.tar
gsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.tar.gz
gsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.tar.bz2
gsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.tar.lz
gsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.tar.xz
gsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.tar.zst
gsoc2013-evolution-056f54ee2814a37f40294c45fc78e49bfb40c358.zip
Was x_evolution_message_parse from folder-browser.c. A space char is no
2001-11-08 Jeffrey Stedfast <fejj@ximian.com> * mail-tools.c (mail_tools_x_evolution_message_parse): Was x_evolution_message_parse from folder-browser.c. A space char is no longer used to separate the folder URI and the first uid, instead this is now done with a nul-char so update to parse the newer/better format. * component-factory.c (destination_folder_handle_drop): Update to parse the new/better format. * folder-browser.c (x_evolution_message_parse): Moved to mail-tools.c (message_list_drag_data_get): Instead of placing a space char after the folder URI, instead use a nul-char. svn path=/trunk/; revision=14645
Diffstat (limited to 'mail/component-factory.c')
-rw-r--r--mail/component-factory.c30
1 files changed, 4 insertions, 26 deletions
diff --git a/mail/component-factory.c b/mail/component-factory.c
index 9d501ba815..f77f76fa1b 100644
--- a/mail/component-factory.c
+++ b/mail/component-factory.c
@@ -623,34 +623,12 @@ destination_folder_handle_drop (EvolutionShellComponentDndDestinationFolder *des
camel_object_unref (CAMEL_OBJECT (folder));
break;
case ACCEPTED_DND_TYPE_X_EVOLUTION_MESSAGE:
- /* format: "uri uid1\0uid2\0uid3\0...\0uidn" */
+ folder = mail_tools_x_evolution_message_parse (data->bytes._buffer,
+ data->bytes._length,
+ &uids);
- in = data->bytes._buffer;
- inend = in + data->bytes._length;
-
- inptr = strchr (in, ' ');
- url = g_strndup (in, inptr - in);
-
- folder = mail_tool_uri_to_folder (url, 0, &ex);
- g_free (url);
-
- if (!folder) {
- camel_exception_clear (&ex);
+ if (!folder)
return FALSE;
- }
-
- /* split the uids */
- inptr++;
- uids = g_ptr_array_new ();
- while (inptr < inend) {
- char *start = inptr;
-
- while (inptr < inend && *inptr)
- inptr++;
-
- g_ptr_array_add (uids, g_strndup (start, inptr - start));
- inptr++;
- }
mail_transfer_messages (folder, uids,
action == GNOME_Evolution_ShellComponentDnd_ACTION_MOVE,