aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--calendar/ChangeLog8
-rw-r--r--calendar/idl/evolution-calendar.idl4
-rw-r--r--calendar/pcs/cal-backend.c7
3 files changed, 16 insertions, 3 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog
index 8969aaa817..53f89b80d8 100644
--- a/calendar/ChangeLog
+++ b/calendar/ChangeLog
@@ -1,3 +1,11 @@
+2000-12-07 JP Rosevear <jpr@helixcode.com>
+
+ * pcs/cal-backend.c (cal_backend_compute_changes_foreach_key): Create
+ an empty cal component if the object has been deleted.
+
+ * idl/evolution-calendar.idl: Bit shift the change type constants
+ properly
+
2000-12-07 Federico Mena Quintero <federico@helixcode.com>
* cal-client/cal-client.c (cal_client_generate_instances): Unref
diff --git a/calendar/idl/evolution-calendar.idl b/calendar/idl/evolution-calendar.idl
index 89926386e2..bee377c76a 100644
--- a/calendar/idl/evolution-calendar.idl
+++ b/calendar/idl/evolution-calendar.idl
@@ -37,8 +37,8 @@ module Calendar {
/* Types of object changes made */
typedef long CalObjChangeType;
const CalObjChangeType ADDED = 1 << 0;
- const CalObjChangeType MODIFIED = 1 << 0;
- const CalObjChangeType DELETED = 1 << 1;
+ const CalObjChangeType MODIFIED = 1 << 1;
+ const CalObjChangeType DELETED = 1 << 2;
/* Types of alarms */
enum AlarmType {
diff --git a/calendar/pcs/cal-backend.c b/calendar/pcs/cal-backend.c
index 5b95f2b80a..ce9604e418 100644
--- a/calendar/pcs/cal-backend.c
+++ b/calendar/pcs/cal-backend.c
@@ -305,10 +305,15 @@ cal_backend_compute_changes_foreach_key (const char *key, gpointer data)
char *calobj = cal_backend_get_object (be_data->backend, key);
if (calobj == NULL) {
+ CalComponent *comp;
GNOME_Evolution_Calendar_CalObjChange *coc;
+ comp = cal_component_new ();
+ cal_component_set_new_vtype (comp, CAL_COMPONENT_TODO);
+ cal_component_set_uid (comp, key);
+
coc = GNOME_Evolution_Calendar_CalObjChange__alloc ();
- coc->calobj = CORBA_string_dup (calobj);
+ coc->calobj = CORBA_string_dup (cal_component_get_as_string (comp));
coc->type = GNOME_Evolution_Calendar_DELETED;
be_data->changes = g_list_prepend (be_data->changes, coc);
be_data->change_ids = g_list_prepend (be_data->change_ids, (gpointer) key);