diff options
author | Chenthill Palanisamy <pchenthill@novell.com> | 2004-12-02 22:05:50 +0800 |
---|---|---|
committer | Chenthill Palanisamy <pchen@src.gnome.org> | 2004-12-02 22:05:50 +0800 |
commit | 300ec3f74d9f2ea59503ad267c927723ea59fd3e (patch) | |
tree | 5b6c2f78eb177f049be8a3e9fd91163e5eb6e7da /calendar/gui/e-calendar-table.c | |
parent | 2f70359db9a97a8e3f13d0ee9970d93a139f839e (diff) | |
download | gsoc2013-evolution-300ec3f74d9f2ea59503ad267c927723ea59fd3e.tar.gz gsoc2013-evolution-300ec3f74d9f2ea59503ad267c927723ea59fd3e.tar.zst gsoc2013-evolution-300ec3f74d9f2ea59503ad267c927723ea59fd3e.zip |
Add a boolean variable to denote assigned task and construct the meeting
2004-12-02 Chenthill Palanisamy <pchenthill@novell.com>
* gui/dialogs/task-editor.[ch] (task_editor_new), (task_editor_construct),
(show_assignment):
Add a boolean variable to denote assigned task and construct the
meeting page only for the assigned task. Set it as a group item
in component editor.
(_TaskEditorPrivate): added the boolean variable (is_assigned).
(task_editor_init): initialized the variable.
* gui/dialogs/comp-editor.[ch]: Added functions to set and get whether comp
is a group item or individual item.
* gui/comp-editor.c (make_title_from_string), (make_title_from_comp):
Set the Title for the appointment editor window as "Meeting" or "Assigned
Task" if its a group calendar/task item.
(_CompEditorPrivate): added a boolean variable (is_group_item).
(comp_editor_init): initialized the same.
* gui/dialogs/event-editor.c (event_editor_construct), (show_meeting): Set whether
the component is a group item or not in comp editor.
* gui/e-calendar-table.c (e_calendar_table_open_task), (e_calendar_table_open_selected),
(open_task_by_row): Check whether the component being opened is an assigned task by
checking for attendees and call open_task with proper value for boolean variable assign.
* gui/comp-editor-factory.c (edit_existing):
* gui/e-calendar-table.c (open_task):
* gui/e-tasks.c (e_tasks_new_task):
* gui/gnome-cal.c (gnome_calendar_new_task):
* gui/tasks-component.c (create_new_todo):
Called the function task_editor_new with a added argument.
svn path=/trunk/; revision=28044
Diffstat (limited to 'calendar/gui/e-calendar-table.c')
-rw-r--r-- | calendar/gui/e-calendar-table.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/calendar/gui/e-calendar-table.c b/calendar/gui/e-calendar-table.c index 1a8020aa02..64193687fa 100644 --- a/calendar/gui/e-calendar-table.c +++ b/calendar/gui/e-calendar-table.c @@ -584,10 +584,12 @@ void e_calendar_table_open_selected (ECalendarTable *cal_table) { ECalModelComponent *comp_data; + icalproperty *prop; comp_data = get_selected_comp (cal_table); + prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY); if (comp_data != NULL) - open_task (cal_table, comp_data, FALSE); + open_task (cal_table, comp_data, prop ? TRUE : FALSE); } /** @@ -940,7 +942,7 @@ open_task (ECalendarTable *cal_table, ECalModelComponent *comp_data, gboolean as if (tedit == NULL) { ECalComponent *comp; - tedit = COMP_EDITOR (task_editor_new (comp_data->client)); + tedit = COMP_EDITOR (task_editor_new (comp_data->client, assign)); comp = e_cal_component_new (); e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (comp_data->icalcomp)); @@ -959,9 +961,11 @@ static void open_task_by_row (ECalendarTable *cal_table, int row) { ECalModelComponent *comp_data; + icalproperty *prop; comp_data = e_cal_model_get_component_at (cal_table->model, row); - open_task (cal_table, comp_data, FALSE); + prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY); + open_task (cal_table, comp_data, prop ? TRUE : FALSE); } static void @@ -981,10 +985,12 @@ e_calendar_table_on_open_task (EPopup *ep, EPopupItem *pitem, void *data) { ECalendarTable *cal_table = data; ECalModelComponent *comp_data; + icalproperty *prop; comp_data = get_selected_comp (cal_table); + prop = icalcomponent_get_first_property (comp_data->icalcomp, ICAL_ATTENDEE_PROPERTY); if (comp_data) - open_task (cal_table, comp_data, FALSE); + open_task (cal_table, comp_data, prop ? TRUE : FALSE); } static void |