diff options
author | Rodrigo Moya <rodrigo@novell.com> | 2005-01-05 02:10:17 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@src.gnome.org> | 2005-01-05 02:10:17 +0800 |
commit | 2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71 (patch) | |
tree | 52ba08752db523f37108347e7f0c06c550487de8 /calendar | |
parent | 6823de81f37ab21ba2a9627ed09ecc52425ba1e0 (diff) | |
download | gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.tar gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.tar.gz gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.tar.bz2 gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.tar.lz gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.tar.xz gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.tar.zst gsoc2013-evolution-2f67df578fe940cf5e7aab8c98b7a0d1c71cfa71.zip |
search our internal data for the correct event.
2005-01-04 Rodrigo Moya <rodrigo@novell.com>
* gui/e-week-view.c (model_rows_deleted_cb): search our internal data
for the correct event.
svn path=/trunk/; revision=28234
Diffstat (limited to 'calendar')
-rw-r--r-- | calendar/ChangeLog | 5 | ||||
-rw-r--r-- | calendar/gui/e-week-view.c | 23 |
2 files changed, 26 insertions, 2 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index edd2193360..508a7be4f2 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,8 @@ +2005-01-04 Rodrigo Moya <rodrigo@novell.com> + + * gui/e-week-view.c (model_rows_deleted_cb): search our internal data + for the correct event. + 2005-01-04 Harry Lu <harry.lu@sun.com> * gui/calendar-component.c: (create_component_view): add a11y name diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c index 08587725b0..50ff88f542 100644 --- a/calendar/gui/e-week-view.c +++ b/calendar/gui/e-week-view.c @@ -399,8 +399,27 @@ model_rows_deleted_cb (ETableModel *etm, int row, int count, gpointer user_data) /* FIXME Stop editing? */ - for (i = row + count; i > row; i--) - e_week_view_remove_event_cb (week_view, i - 1, NULL); + for (i = row + count; i > row; i--) { + gint event_num; + const char *uid, *rid = NULL; + ECalModelComponent *comp_data; + + comp_data = e_cal_model_get_component_at (E_CAL_MODEL (etm), i - 1); + if (!comp_data) + continue; + + uid = icalcomponent_get_uid (comp_data->icalcomp); + if (e_cal_util_component_is_instance (comp_data->icalcomp)) { + icalproperty *prop; + + prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_RECURRENCEID_PROPERTY); + if (prop) + rid = icaltime_as_ical_string (icalcomponent_get_recurrenceid (comp_data->icalcomp)); + } + + if (e_week_view_find_event_from_uid (week_view, uid, rid, &event_num)) + e_week_view_remove_event_cb (week_view, event_num, NULL); + } gtk_widget_queue_draw (week_view->main_canvas); e_week_view_queue_layout (week_view); |