aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJP Rosevear <jpr@ximian.com>2002-09-24 22:05:00 +0800
committerJP Rosevear <jpr@src.gnome.org>2002-09-24 22:05:00 +0800
commit91875b613e4f475825c4ae9c2532f57443070d58 (patch)
treea4d1fbac1f2d09d35b8c7a35becfeb887c387bec
parentce792ef0ec703c53473ca82b5085ef59c2b9d558 (diff)
downloadgsoc2013-evolution-91875b613e4f475825c4ae9c2532f57443070d58.tar.gz
gsoc2013-evolution-91875b613e4f475825c4ae9c2532f57443070d58.tar.zst
gsoc2013-evolution-91875b613e4f475825c4ae9c2532f57443070d58.zip
convert to date values if the original start and end were both dates
2002-09-24 JP Rosevear <jpr@ximian.com> * conduits/calendar/calendar-conduit.c (process_multi_day): convert to date values if the original start and end were both dates svn path=/trunk/; revision=18198
-rw-r--r--calendar/ChangeLog6
-rw-r--r--calendar/conduits/calendar/calendar-conduit.c8
2 files changed, 12 insertions, 2 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog
index f65572ecf9..6beff2acdf 100644
--- a/calendar/ChangeLog
+++ b/calendar/ChangeLog
@@ -1,3 +1,9 @@
+2002-09-24 JP Rosevear <jpr@ximian.com>
+
+ * conduits/calendar/calendar-conduit.c (process_multi_day):
+ convert to date values if the original start and end were both
+ dates
+
2002-09-24 Rodrigo Moya <rodrigo@ximian.com>
* cal-client/cal-query.c (cal_query_destroy): unref the query
diff --git a/calendar/conduits/calendar/calendar-conduit.c b/calendar/conduits/calendar/calendar-conduit.c
index 6dfe288f34..d057ed49fe 100644
--- a/calendar/conduits/calendar/calendar-conduit.c
+++ b/calendar/conduits/calendar/calendar-conduit.c
@@ -497,6 +497,7 @@ process_multi_day (ECalConduitContext *ctxt, CalClientChange *ccc, GList **multi
time_t event_start, event_end, day_end;
struct icaltimetype *old_start_value, *old_end_value;
const char *uid;
+ gboolean is_date = FALSE;
gboolean last = FALSE;
gboolean ret = TRUE;
@@ -530,6 +531,9 @@ process_multi_day (ECalConduitContext *ctxt, CalClientChange *ccc, GList **multi
goto cleanup;
}
+ if (dt_start.value->is_date && dt_end.value->is_date)
+ is_date = TRUE;
+
old_start_value = dt_start.value;
old_end_value = dt_end.value;
while (!last) {
@@ -545,11 +549,11 @@ process_multi_day (ECalConduitContext *ctxt, CalClientChange *ccc, GList **multi
cal_component_set_uid (clone, new_uid);
- start_value = icaltime_from_timet_with_zone (event_start, FALSE, tz_start);
+ start_value = icaltime_from_timet_with_zone (event_start, is_date, tz_start);
dt_start.value = &start_value;
cal_component_set_dtstart (clone, &dt_start);
- end_value = icaltime_from_timet_with_zone (day_end, FALSE, tz_end);
+ end_value = icaltime_from_timet_with_zone (day_end, is_date, tz_end);
dt_end.value = &end_value;
cal_component_set_dtend (clone, &dt_end);