[evolution-patches] fix for the bug #310328 [calendar]



Hi,
   Have attached the patch.

thanks, chenthill.
Index: servers/groupwise/ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution-data-server/servers/groupwise/ChangeLog,v
retrieving revision 1.156
diff -u -p -r1.156 ChangeLog
--- servers/groupwise/ChangeLog	29 Jul 2005 17:39:13 -0000	1.156
+++ servers/groupwise/ChangeLog	2 Aug 2005 10:32:28 -0000
@@ -1,3 +1,9 @@
+2005-08-02  Chenthill Palanisamy  <pchenthill novell com>
+
+	* e-gw-item.c: (e_gw_item_new_from_soap_parameter): Check
+	for the element startDay or endDay and do the same as startDate
+	and endDate.
+
 2005-07-29  Parthasarathi Susarla <sparthasarathi novell com>
 	
 	* e-gw-item.c: 
Index: servers/groupwise/e-gw-item.c
===================================================================
RCS file: /cvs/gnome/evolution-data-server/servers/groupwise/e-gw-item.c,v
retrieving revision 1.90
diff -u -p -r1.90 e-gw-item.c
--- servers/groupwise/e-gw-item.c	25 Jul 2005 13:55:19 -0000	1.90
+++ servers/groupwise/e-gw-item.c	2 Aug 2005 10:32:28 -0000
@@ -1814,7 +1814,7 @@ e_gw_item_new_from_soap_parameter (const
 			g_free (value);
 			g_free (formatted_date);
 		
-		} else if (!g_ascii_strcasecmp (name, "endDate")) {
+		} else if (!g_ascii_strcasecmp (name, "endDate") || !g_ascii_strcasecmp (name, "endDay")) {
 			char *formatted_date; 
 			value = soup_soap_parameter_get_string_value (child);
 			formatted_date = e_gw_connection_format_date_string (value);
@@ -1916,7 +1916,7 @@ e_gw_item_new_from_soap_parameter (const
 			g_free (priority);
 		}
 
-		else if (!g_ascii_strcasecmp (name, "startDate")) {
+		else if (!g_ascii_strcasecmp (name, "startDate") || !g_ascii_strcasecmp (name, "startDay")) {
 			char *formatted_date;
 			value = soup_soap_parameter_get_string_value (child);
 			formatted_date = e_gw_connection_format_date_string (value);
Index: calendar/ChangeLog
===================================================================
RCS file: /cvs/gnome/evolution-data-server/calendar/ChangeLog,v
retrieving revision 1.488
diff -u -p -r1.488 ChangeLog
--- calendar/ChangeLog	27 Jul 2005 10:57:20 -0000	1.488
+++ calendar/ChangeLog	2 Aug 2005 10:32:29 -0000
@@ -1,3 +1,10 @@
+2005-08-02  Chenthill Palanisamy  <pchenthill novell com>
+
+	Fixes #310328
+	* backends/groupwise/e-cal-backend-groupwise-utils.c:
+	(e_gw_item_to_cal_component): Assign the date value alone
+	for start and end date if its an allday event.
+
 2005-07-27  Mengjie Yu  <meng-jie yu sun com>
 
 	* backends/file/e-cal-backend-file-events.c:
Index: calendar/backends/groupwise/e-cal-backend-groupwise-utils.c
===================================================================
RCS file: /cvs/gnome/evolution-data-server/calendar/backends/groupwise/e-cal-backend-groupwise-utils.c,v
retrieving revision 1.59
diff -u -p -r1.59 e-cal-backend-groupwise-utils.c
--- calendar/backends/groupwise/e-cal-backend-groupwise-utils.c	27 Jul 2005 10:57:21 -0000	1.59
+++ calendar/backends/groupwise/e-cal-backend-groupwise-utils.c	2 Aug 2005 10:32:30 -0000
@@ -928,21 +928,23 @@ e_gw_item_to_cal_component (EGwItem *ite
 	t = e_gw_item_get_start_date (item);
 	if (t) {
 		itt_utc = icaltime_from_string (t);
-		if (!icaltime_get_timezone (itt_utc))
-			icaltime_set_timezone (&itt_utc, icaltimezone_get_utc_timezone());
-		if (default_zone) {
-			itt = icaltime_convert_to_zone (itt_utc, default_zone); 
-			icaltime_set_timezone (&itt, default_zone);
-			dt.value = &itt;
-			dt.tzid = icaltimezone_get_tzid (default_zone);
+		
+		if (!is_allday) {
+			if (!icaltime_get_timezone (itt_utc))
+				icaltime_set_timezone (&itt_utc, icaltimezone_get_utc_timezone());
+			if (default_zone) {
+				itt = icaltime_convert_to_zone (itt_utc, default_zone); 
+				icaltime_set_timezone (&itt, default_zone);
+				dt.value = &itt;
+				dt.tzid = icaltimezone_get_tzid (default_zone);
+			} else {
+				dt.value = &itt_utc;
+				dt.tzid = g_strdup ("UTC");
+			}
 		} else {
 			dt.value = &itt_utc;
-			dt.tzid = g_strdup ("UTC");
-		}
-		if (is_allday) {
-			dt.value->is_date = 1;
-			dt.tzid = NULL;
-		}
+		}	
+
 		e_cal_component_set_dtstart (comp, &dt);
 		g_free (t);
 	}
@@ -1054,24 +1056,26 @@ e_gw_item_to_cal_component (EGwItem *ite
 		t = e_gw_item_get_end_date (item);
 		if (t) {
 			itt_utc = icaltime_from_string (t);
-			if (!icaltime_get_timezone (itt_utc))
-				icaltime_set_timezone (&itt_utc, icaltimezone_get_utc_timezone());
-			if (default_zone) {
-				itt = icaltime_convert_to_zone (itt_utc, default_zone); 
-				icaltime_set_timezone (&itt, default_zone);
-				dt.value = &itt;
-				dt.tzid = icaltimezone_get_tzid (default_zone);
+
+			if (!is_allday) {
+				if (!icaltime_get_timezone (itt_utc))
+					icaltime_set_timezone (&itt_utc, icaltimezone_get_utc_timezone());
+				if (default_zone) {
+					itt = icaltime_convert_to_zone (itt_utc, default_zone); 
+					icaltime_set_timezone (&itt, default_zone);
+					dt.value = &itt;
+					dt.tzid = icaltimezone_get_tzid (default_zone);
+				} else {
+					dt.value = &itt_utc;
+					dt.tzid = g_strdup ("UTC");
+				}
 			} else {
 				dt.value = &itt_utc;
-				dt.tzid = g_strdup ("UTC");
 			}
-			if (is_allday) {
-				dt.value->is_date = 1;
-				dt.tzid = NULL;
-			}	
+
 			e_cal_component_set_dtend (comp, &dt);
 		}
-		
+
 
 		/* alarms*/
 		/* we negate the value as GW supports only "before" the start of event alarms */


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