diff options
author | Chenthill Palanisamy <pchen@src.gnome.org> | 2006-12-04 17:43:51 +0800 |
---|---|---|
committer | Chenthill Palanisamy <pchen@src.gnome.org> | 2006-12-04 17:43:51 +0800 |
commit | 0db239af79eef98aaae13e887814460c5d0bcfd9 (patch) | |
tree | 3eb13a5089130386df0f921cc12505d010384a34 /calendar/gui/e-tasks.c | |
parent | e37627d16f5d85cef7e143b32764529ad109d178 (diff) | |
download | gsoc2013-evolution-0db239af79eef98aaae13e887814460c5d0bcfd9.tar.gz gsoc2013-evolution-0db239af79eef98aaae13e887814460c5d0bcfd9.tar.zst gsoc2013-evolution-0db239af79eef98aaae13e887814460c5d0bcfd9.zip |
Fixes #270751
svn path=/trunk/; revision=33040
Diffstat (limited to 'calendar/gui/e-tasks.c')
-rw-r--r-- | calendar/gui/e-tasks.c | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/calendar/gui/e-tasks.c b/calendar/gui/e-tasks.c index 0c533adc75..14a2a80ffc 100644 --- a/calendar/gui/e-tasks.c +++ b/calendar/gui/e-tasks.c @@ -1415,6 +1415,43 @@ e_tasks_discard_view_menus (ETasks *tasks) priv->view_menus = NULL; } +void +e_tasks_open_task_id (ETasks *tasks, + const char *src_uid, + const char *comp_uid, + const char *comp_rid) +{ + ECal *client = NULL; + GList *l; + icalcomponent* icalcomp = NULL; + icalproperty *attendee_prop = NULL; + + if (!src_uid || !comp_uid) + return; + + for (l = tasks->priv->clients_list; l != NULL; l = l->next) { + client = l->data; + ESource *client_src = e_cal_get_source (client); + + if (!strcmp (src_uid, e_source_peek_uid (client_src))) + break; + } + + if (!client) + return; + + e_cal_get_object (client, comp_uid, comp_rid, &icalcomp, NULL); + + if (!icalcomp) + return; + + attendee_prop = icalcomponent_get_first_property (icalcomp, ICAL_ATTENDEE_PROPERTY); + e_calendar_table_open_task (E_CALENDAR_TABLE (tasks->priv->tasks_view), client, icalcomp, attendee_prop); + icalcomponent_free (icalcomp); + + return; +} + /** * e_tasks_get_calendar_table: * @tasks: A tasks widget. |