diff options
-rw-r--r-- | calendar/ChangeLog | 7 | ||||
-rw-r--r-- | calendar/gui/e-calendar-table.c | 12 |
2 files changed, 14 insertions, 5 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index b61f1ed39f..1b119ab6d6 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -23,6 +23,13 @@ 2004-01-17 JP Rosevear <jpr@ximian.com> + * gui/e-calendar-table.c (e_calendar_table_delete_selected): don't + create the component if there is a multiple selection + + Fixes #52266 + +2004-01-17 JP Rosevear <jpr@ximian.com> + * gui/e-cal-view.c (on_print): we are required to pass in the end in-out arg diff --git a/calendar/gui/e-calendar-table.c b/calendar/gui/e-calendar-table.c index 455cbbba8b..eff99818ad 100644 --- a/calendar/gui/e-calendar-table.c +++ b/calendar/gui/e-calendar-table.c @@ -724,7 +724,7 @@ e_calendar_table_delete_selected (ECalendarTable *cal_table) ETable *etable; int n_selected; ECalModelComponent *comp_data; - ECalComponent *comp; + ECalComponent *comp = NULL; g_return_if_fail (cal_table != NULL); g_return_if_fail (E_IS_CALENDAR_TABLE (cal_table)); @@ -742,16 +742,18 @@ e_calendar_table_delete_selected (ECalendarTable *cal_table) /* FIXME: this may be something other than a TODO component */ - comp = e_cal_component_new (); - if (comp_data) + if (comp_data) { + comp = e_cal_component_new (); e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp)); - + } + if (delete_component_dialog (comp, FALSE, n_selected, E_CAL_COMPONENT_TODO, GTK_WIDGET (cal_table))) delete_selected_components (cal_table); /* free memory */ - g_object_unref (comp); + if (comp) + g_object_unref (comp); } /** |