From 6aec39ddd634e28d61401295f0e5ec0a115ad62d Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Mon, 3 May 2004 12:56:02 +0000 Subject: Fixes #57894 2004-05-03 JP Rosevear Fixes #57894 * gui/gnome-cal.c (gnome_calendar_new_task): make sure we use the default component of the correct model svn path=/trunk/; revision=25748 --- calendar/ChangeLog | 7 +++++++ calendar/gui/gnome-cal.c | 6 ++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 53be8616f7..650a7d8fd9 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,10 @@ +2004-05-03 JP Rosevear + + Fixes #57894 + + * gui/gnome-cal.c (gnome_calendar_new_task): make sure we use the + default component of the correct model + 2004-04-30 Rodney Dawes * gui/alarm-notify/alarm-notify-dialog.c (alarm_notify_dialog): diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c index b35a524995..800fa966df 100644 --- a/calendar/gui/gnome-cal.c +++ b/calendar/gui/gnome-cal.c @@ -2390,6 +2390,7 @@ gnome_calendar_new_task (GnomeCalendar *gcal) { GnomeCalendarPrivate *priv; ECal *ecal; + ECalModel *model; TaskEditor *tedit; ECalComponent *comp; icalcomponent *icalcomp; @@ -2400,10 +2401,11 @@ gnome_calendar_new_task (GnomeCalendar *gcal) priv = gcal->priv; - ecal = e_cal_model_get_default_client (e_calendar_table_get_model (E_CALENDAR_TABLE (priv->todo))); + model = e_calendar_table_get_model (E_CALENDAR_TABLE (priv->todo)); + ecal = e_cal_model_get_default_client (model); tedit = task_editor_new (ecal); - icalcomp = e_cal_model_create_component_with_defaults (e_calendar_view_get_model (E_CALENDAR_VIEW (priv->week_view))); + icalcomp = e_cal_model_create_component_with_defaults (model); comp = e_cal_component_new (); e_cal_component_set_icalcomponent (comp, icalcomp); -- cgit v1.2.3