From 1af092ec093994115d64ed30f04d11bb322aba35 Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Fri, 30 Nov 2001 02:12:13 +0000 Subject: Set the category of the new task to that of the search bar. Fixes bug 2001-11-28 Federico Mena Quintero * gui/gnome-cal.c (gnome_calendar_new_task): Set the category of the new task to that of the search bar. Fixes bug #15533. svn path=/trunk/; revision=14821 --- calendar/ChangeLog | 5 +++++ calendar/gui/gnome-cal.c | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 71ecf38821..337d6c45fe 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,8 @@ +2001-11-28 Federico Mena Quintero + + * gui/gnome-cal.c (gnome_calendar_new_task): Set the category of + the new task to that of the search bar. Fixes bug #15533. + 2001-11-27 Rodrigo Moya * gui/e-itip-control.c (update_attendee_status): diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c index 98c01e6372..bc9e426ef4 100644 --- a/calendar/gui/gnome-cal.c +++ b/calendar/gui/gnome-cal.c @@ -2271,6 +2271,7 @@ gnome_calendar_new_task (GnomeCalendar *gcal) GnomeCalendarPrivate *priv; TaskEditor *tedit; CalComponent *comp; + const char *category; g_return_if_fail (gcal != NULL); g_return_if_fail (GNOME_IS_CALENDAR (gcal)); @@ -2283,6 +2284,9 @@ gnome_calendar_new_task (GnomeCalendar *gcal) comp = cal_component_new (); cal_component_set_new_vtype (comp, CAL_COMPONENT_TODO); + category = cal_search_bar_get_category (CAL_SEARCH_BAR (priv->search_bar)); + cal_component_set_categories (comp, category); + comp_editor_edit_comp (COMP_EDITOR (tedit), comp); gtk_object_unref (GTK_OBJECT (comp)); -- cgit v1.2.3