evolution-data-server r9844 - trunk/camel/providers/groupwise



Author: abharath
Date: Tue Dec 23 09:05:31 2008
New Revision: 9844
URL: http://svn.gnome.org/viewvc/evolution-data-server?rev=9844&view=rev

Log:
2008-12-23  Bharath Acharya  <abharath novell com>

        ** Fix for bnc bug #449916

        * camel-groupwise-folder.c: (convert_to_task), (convert_to_note): 
        Display multiple lines of an assigned task or shared memo.


Modified:
   trunk/camel/providers/groupwise/ChangeLog
   trunk/camel/providers/groupwise/camel-groupwise-folder.c

Modified: trunk/camel/providers/groupwise/camel-groupwise-folder.c
==============================================================================
--- trunk/camel/providers/groupwise/camel-groupwise-folder.c	(original)
+++ trunk/camel/providers/groupwise/camel-groupwise-folder.c	Tue Dec 23 09:05:31 2008
@@ -2690,7 +2690,21 @@
 	g_string_append_printf (gstr, "UID:%s\n",e_gw_item_get_icalid (item));
 	g_string_append_printf (gstr, "DTSTART:%s\n",e_gw_item_get_start_date (item));
 	g_string_append_printf (gstr, "SUMMARY:%s\n", e_gw_item_get_subject (item));
-	g_string_append_printf (gstr, "DESCRIPTION:%s\n", e_gw_item_get_message (item));
+
+	temp = e_gw_item_get_message (item);
+	if (temp) {
+		g_string_append(gstr, "DESCRIPTION:");
+		while (*temp) {
+			if (*temp == '\n')
+				g_string_append(gstr, "\\n");
+			else
+				g_string_append_c(gstr, *temp);
+			temp++;
+		}
+		g_string_append(gstr, "\n");	
+	}
+	temp = NULL;
+
 	g_string_append_printf (gstr, "DTSTAMP:%s\n", e_gw_item_get_creation_date (item));
 	g_string_append_printf (gstr, "X-GWMESSAGEID:%s\n", e_gw_item_get_id (item));
 	g_string_append_printf (gstr, "X-GWSHOW-AS:BUSY\n");
@@ -2745,6 +2759,7 @@
 	EGwItemOrganizer *org = NULL;
 	GString *gstr = g_string_new (NULL);
 	char **tmp = NULL;
+	const char *temp = NULL;
 
 	tmp = g_strsplit (e_gw_item_get_id (item), "@", -1);
 
@@ -2754,7 +2769,21 @@
 	g_string_append_printf (gstr, "UID:%s\n",e_gw_item_get_icalid (item));
 	g_string_append_printf (gstr, "DTSTART:%s\n",e_gw_item_get_start_date (item));
 	g_string_append_printf (gstr, "SUMMARY:%s\n", e_gw_item_get_subject (item));
-	g_string_append_printf (gstr, "DESCRIPTION:%s\n", e_gw_item_get_message (item));
+
+	temp = e_gw_item_get_message (item);
+	if (temp) {
+		g_string_append(gstr, "DESCRIPTION:");
+		while (*temp) {
+			if (*temp == '\n')
+				g_string_append(gstr, "\\n");
+			else
+				g_string_append_c(gstr, *temp);
+			temp++;
+		}
+		g_string_append(gstr, "\n");	
+	}
+	temp = NULL;
+
 	g_string_append_printf (gstr, "DTSTAMP:%s\n", e_gw_item_get_creation_date (item));
 	g_string_append_printf (gstr, "X-GWMESSAGEID:%s\n", e_gw_item_get_id (item));
 	g_string_append_printf (gstr, "X-GWRECORDID:%s\n", tmp[0]);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]