[evolution-exchange] Bug #403903 - Appointments don't display in Windows Mobile 5



commit 8388b7af7a6666c9e1c14368709101c915aea820
Author: Peter <peter petesbox net>
Date:   Thu Apr 29 21:05:00 2010 +0200

    Bug #403903 - Appointments don't display in Windows Mobile 5

 calendar/e-cal-backend-exchange-calendar.c |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)
---
diff --git a/calendar/e-cal-backend-exchange-calendar.c b/calendar/e-cal-backend-exchange-calendar.c
index e17f495..8a84afa 100644
--- a/calendar/e-cal-backend-exchange-calendar.c
+++ b/calendar/e-cal-backend-exchange-calendar.c
@@ -748,6 +748,7 @@ create_object (ECalBackendSync *backend, EDataCal *cal,
 	E2kContext *e2kctx;
 	struct _cb_data *cbdata;
 	gboolean send_options;
+	ECalComponentClassification classif;
 
 	d(printf ("ecbexc_create_object(%p, %p, %s, %s)", backend, cal, *calobj ? *calobj : NULL, *uid ? *uid : NULL));
 
@@ -836,6 +837,17 @@ create_object (ECalBackendSync *backend, EDataCal *cal,
 	cbdata->vcal_comp = e_cal_util_new_top_level ();
 	cbdata->cal = cal;
 
+	/* Though OWA produces "CLASS:" (which we map to
+	 * "CLASS:PUBLIC" above), it will accept "CLASS:PUBLIC".
+	 * However, some other exchange clients, notably Windows
+	 * Mobile Outlook, don't work unless we map "CLASS:PUBLIC"
+	 * back to "CLASS:". For details, see
+	 * https://bugzilla.gnome.org/show_bug.cgi?id=403903#c23
+	 */
+	e_cal_component_get_classification (comp, &classif);
+	if (classif == E_CAL_COMPONENT_CLASS_PUBLIC)
+		e_cal_component_set_classification (comp, E_CAL_COMPONENT_CLASS_NONE);
+
 	/* Remove X parameters from properties */
 	/* This is specifically for X-EVOLUTION-END-DATE,
 	   but removing anything else is probably ok too */



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