From 5f6a18500c3119731663ac4c059426c62a3b37f6 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Wed, 13 Aug 2008 12:00:21 +0000 Subject: Merge revisions 35931:35950 from trunk. svn path=/branches/kill-bonobo/; revision=35978 --- calendar/gui/itip-utils.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index c60b7d3dc1..616e1edbe7 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1142,9 +1142,9 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, ECalComponent *comp = NULL; icalcomponent *top_level = NULL; char *ical_string = NULL; - gchar *from; - gchar *content_type; - gchar *subject; + gchar *from = NULL; + gchar *content_type = NULL; + gchar *subject = NULL; gboolean retval = FALSE; /* check whether backend could handle sending requests/updates */ -- cgit v1.2.3 From 098ea8aad8d3249d9faca5df5b4fe67b94ba660f Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Mon, 29 Sep 2008 16:14:46 +0000 Subject: Get Memos to come up. Doesn't really work yet, but the widgets are all there. svn path=/branches/kill-bonobo/; revision=36491 --- calendar/gui/itip-utils.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 616e1edbe7..b70225bbe6 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1098,6 +1098,7 @@ append_cal_attachments (EMsgComposer *composer, ECalComponent *comp, GSList *attach_list) { +#if 0 /* KILL-BONOBO */ struct CalMimeAttach *mime_attach; GSList *l; @@ -1130,12 +1131,14 @@ append_cal_attachments (EMsgComposer *composer, g_free (mime_attach->description); g_free (mime_attach->encoded_data); } +#endif } gboolean itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users) { +#if 0 /* KILL-BONOBO */ EMsgComposer *composer; EComposerHeaderTable *table; EDestination **destinations; @@ -1183,9 +1186,11 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, table = e_msg_composer_get_header_table (composer); em_composer_utils_setup_default_callbacks (composer); +#if 0 /* KILL-BONOBO */ e_composer_header_table_set_subject (table, subject); e_composer_header_table_set_account_name (table, from); e_composer_header_table_set_destinations_to (table, destinations); +#endif e_destination_freev (destinations); @@ -1252,6 +1257,9 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, g_free (ical_string); return retval; +#endif + + return FALSE; } gboolean @@ -1262,6 +1270,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, icalcomponent *zones, GSList *attachments_list) { +#if 0 /* KILL-BONOBO */ EMsgComposer *composer; EComposerHeaderTable *table; EDestination **destinations; @@ -1291,9 +1300,11 @@ reply_to_calendar_comp (ECalComponentItipMethod method, table = e_msg_composer_get_header_table (composer); em_composer_utils_setup_default_callbacks (composer); +#if 0 /* KILL-BONOBO */ e_composer_header_table_set_subject (table, subject); e_composer_header_table_set_account_name (table, from); e_composer_header_table_set_destinations_to (table, destinations); +#endif e_destination_freev (destinations); @@ -1416,6 +1427,9 @@ reply_to_calendar_comp (ECalComponentItipMethod method, g_free (subject); g_free (ical_string); return retval; +#endif + + return FALSE; } gboolean -- cgit v1.2.3 From b2cda1d0c6d44f53f71bad9e256f41188677dfba Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Wed, 1 Oct 2008 20:56:04 +0000 Subject: Merge revisions 36016:36533 from trunk. svn path=/branches/kill-bonobo/; revision=36534 --- calendar/gui/itip-utils.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index b70225bbe6..eb407a8117 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1,23 +1,23 @@ -/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */ /* - * Authors: - * JP Rosevear - * - * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) - * * This program is free software; you can redistribute it and/or - * modify it under the terms of version 2 of the GNU General Public - * License as published by the Free Software Foundation. + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) version 3. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with the program; if not, see + * + * + * Authors: + * JP Rosevear + * + * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com) * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 - * USA */ #ifdef HAVE_CONFIG_H -- cgit v1.2.3 From e89232e97e2e4a1e7e084ea32f9a078754e8ebfc Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Fri, 31 Oct 2008 16:53:15 +0000 Subject: Get composer integration working with the rest of the modules, but man do we have circular dependencies all over the place! Big house of cards. svn path=/branches/kill-bonobo/; revision=36706 --- calendar/gui/itip-utils.c | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index eb407a8117..5a954b5ff9 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1098,7 +1098,6 @@ append_cal_attachments (EMsgComposer *composer, ECalComponent *comp, GSList *attach_list) { -#if 0 /* KILL-BONOBO */ struct CalMimeAttach *mime_attach; GSList *l; @@ -1131,14 +1130,12 @@ append_cal_attachments (EMsgComposer *composer, g_free (mime_attach->description); g_free (mime_attach->encoded_data); } -#endif } gboolean itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users) { -#if 0 /* KILL-BONOBO */ EMsgComposer *composer; EComposerHeaderTable *table; EDestination **destinations; @@ -1186,11 +1183,9 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, table = e_msg_composer_get_header_table (composer); em_composer_utils_setup_default_callbacks (composer); -#if 0 /* KILL-BONOBO */ e_composer_header_table_set_subject (table, subject); e_composer_header_table_set_account_name (table, from); e_composer_header_table_set_destinations_to (table, destinations); -#endif e_destination_freev (destinations); @@ -1212,7 +1207,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, description = comp_description (comp); body = camel_text_to_html ( - body, CAMEL_MIME_FILTER_TOHTML_PRE, 0); + description, CAMEL_MIME_FILTER_TOHTML_PRE, 0); e_msg_composer_set_body_text (composer, body, -1); g_free (body); @@ -1257,9 +1252,6 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, g_free (ical_string); return retval; -#endif - - return FALSE; } gboolean @@ -1270,7 +1262,6 @@ reply_to_calendar_comp (ECalComponentItipMethod method, icalcomponent *zones, GSList *attachments_list) { -#if 0 /* KILL-BONOBO */ EMsgComposer *composer; EComposerHeaderTable *table; EDestination **destinations; @@ -1300,11 +1291,9 @@ reply_to_calendar_comp (ECalComponentItipMethod method, table = e_msg_composer_get_header_table (composer); em_composer_utils_setup_default_callbacks (composer); -#if 0 /* KILL-BONOBO */ e_composer_header_table_set_subject (table, subject); e_composer_header_table_set_account_name (table, from); e_composer_header_table_set_destinations_to (table, destinations); -#endif e_destination_freev (destinations); @@ -1427,9 +1416,6 @@ reply_to_calendar_comp (ECalComponentItipMethod method, g_free (subject); g_free (ical_string); return retval; -#endif - - return FALSE; } gboolean -- cgit v1.2.3 From d158af8cdfa6e4bf85c1e74769e8d61bc469494c Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Wed, 10 Dec 2008 18:30:29 +0000 Subject: Merge revisions 36811:36865 from trunk. svn path=/branches/kill-bonobo/; revision=36867 --- calendar/gui/itip-utils.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 5a954b5ff9..5b292e1901 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1147,7 +1147,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, gchar *subject = NULL; gboolean retval = FALSE; - /* check whether backend could handle sending requests/updates */ + /* check whether backend could handle auto-saving requests/updates */ if (method != E_CAL_COMPONENT_METHOD_PUBLISH && e_cal_get_save_schedules (client)) return TRUE; @@ -1157,6 +1157,15 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, goto cleanup; } + /* check whether backend could handle sending requests/updates */ + if (method != E_CAL_COMPONENT_METHOD_PUBLISH && e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_CREATE_MESSAGES)) { + if (users) { + g_list_foreach (users, (GFunc) g_free, NULL); + g_list_free (users); + } + return TRUE; + } + /* Tidy up the comp */ comp = comp_compliant (method, send_comp, client, zones); -- cgit v1.2.3 From c7d3c9f95609123035ebaa267f9d2e6ecfa8c2e8 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Mon, 12 Jan 2009 04:12:01 +0000 Subject: Merge revisions 36866:37046 from trunk. svn path=/branches/kill-bonobo/; revision=37050 --- calendar/gui/itip-utils.c | 49 ++++++++++++++++++++++++++++++++++++++--------- 1 file changed, 40 insertions(+), 9 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 5b292e1901..3de75cf3d3 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -661,16 +661,32 @@ comp_subject (ECalComponentItipMethod method, ECalComponent *comp) switch (a->status) { case ICAL_PARTSTAT_ACCEPTED: - prefix = _("Accepted"); + /* Translators: This is part of the subject + * line of a meeting request or update email. + * The full subject line would be: + * "Accepted: Meeting Name". */ + prefix = C_("Meeting", "Accepted"); break; case ICAL_PARTSTAT_TENTATIVE: - prefix = _("Tentatively Accepted"); + /* Translators: This is part of the subject + * line of a meeting request or update email. + * The full subject line would be: + * "Tentatively Accepted: Meeting Name". */ + prefix = C_("Meeting", "Tentatively Accepted"); break; case ICAL_PARTSTAT_DECLINED: - prefix = _("Declined"); + /* Translators: This is part of the subject + * line of a meeting request or update email. + * The full subject line would be: + * "Declined: Meeting Name". */ + prefix = C_("Meeting", "Declined"); break; case ICAL_PARTSTAT_DELEGATED: - prefix = _("Delegated"); + /* Translators: This is part of the subject + * line of a meeting request or update email. + * The full subject line would be: + * "Delegated: Meeting Name". */ + prefix = C_("Meeting", "Delegated"); break; default: break; @@ -680,23 +696,38 @@ comp_subject (ECalComponentItipMethod method, ECalComponent *comp) break; case E_CAL_COMPONENT_METHOD_ADD: - prefix = _("Updated"); + /* Translators: This is part of the subject line of a + * meeting request or update email. The full subject + * line would be: "Updated: Meeting Name". */ + prefix = C_("Meeting", "Updated"); break; case E_CAL_COMPONENT_METHOD_CANCEL: - prefix = _("Cancel"); + /* Translators: This is part of the subject line of a + * meeting request or update email. The full subject + * line would be: "Cancel: Meeting Name". */ + prefix = C_("Meeting", "Cancel"); break; case E_CAL_COMPONENT_METHOD_REFRESH: - prefix = _("Refresh"); + /* Translators: This is part of the subject line of a + * meeting request or update email. The full subject + * line would be: "Refresh: Meeting Name". */ + prefix = C_("Meeting", "Refresh"); break; case E_CAL_COMPONENT_METHOD_COUNTER: - prefix = _("Counter-proposal"); + /* Translators: This is part of the subject line of a + * meeting request or update email. The full subject + * line would be: "Counter-proposal: Meeting Name". */ + prefix = C_("Meeting", "Counter-proposal"); break; case E_CAL_COMPONENT_METHOD_DECLINECOUNTER: - prefix = _("Declined"); + /* Translators: This is part of the subject line of a + * meeting request or update email. The full subject + * line would be: "Declined: Meeting Name". */ + prefix = C_("Meeting", "Declined"); break; default: -- cgit v1.2.3 From 5a1c48696363e3f3c7ffe11bdffdcad6557f811a Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 20 Jan 2009 04:33:23 +0000 Subject: Untangle some circular dependencies with the composer. Addressbook and calendar no longer depend on the mailer. svn path=/branches/kill-bonobo/; revision=37107 --- calendar/gui/itip-utils.c | 3 --- 1 file changed, 3 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 3de75cf3d3..e879a9b440 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -37,7 +37,6 @@ #include #include -#include #include static gchar *itip_methods[] = { @@ -1221,7 +1220,6 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, composer = e_msg_composer_new (); table = e_msg_composer_get_header_table (composer); - em_composer_utils_setup_default_callbacks (composer); e_composer_header_table_set_subject (table, subject); e_composer_header_table_set_account_name (table, from); @@ -1329,7 +1327,6 @@ reply_to_calendar_comp (ECalComponentItipMethod method, composer = e_msg_composer_new (); table = e_msg_composer_get_header_table (composer); - em_composer_utils_setup_default_callbacks (composer); e_composer_header_table_set_subject (table, subject); e_composer_header_table_set_account_name (table, from); -- cgit v1.2.3 From ab00f5b08adb1d74a0c70d935a32ffd982e86f34 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Wed, 21 Jan 2009 02:52:05 +0000 Subject: Merge revisions 37075:37107 from trunk. svn path=/branches/kill-bonobo/; revision=37112 --- calendar/gui/itip-utils.c | 35 +++++++++++++++++++++++++++++------ 1 file changed, 29 insertions(+), 6 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index e879a9b440..17a5d97fb5 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1023,7 +1023,7 @@ comp_minimal (ECalComponent *comp, gboolean attendee) } static ECalComponent * -comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *client, icalcomponent *zones) +comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *client, icalcomponent *zones, gboolean strip_alarms) { ECalComponent *clone, *temp_clone; struct icaltimetype itt; @@ -1080,8 +1080,31 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien e_cal_component_free_recur_list (rrule_list); } - /* We delete incoming alarms anyhow, and this helps with outlook */ - e_cal_component_remove_all_alarms (clone); + /* We delete incoming alarms if requested, even this helps with outlook */ + if (strip_alarms) { + e_cal_component_remove_all_alarms (clone); + } else { + /* Always strip procedure alarms, because of security */ + GList *uids, *l; + + uids = e_cal_component_get_alarm_uids (clone); + + for (l = uids; l; l = l->next) { + ECalComponentAlarm *alarm; + ECalComponentAlarmAction action = E_CAL_COMPONENT_ALARM_UNKNOWN; + + alarm = e_cal_component_get_alarm (clone, (const char *)l->data); + if (alarm) { + e_cal_component_alarm_get_action (alarm, &action); + e_cal_component_alarm_free (alarm); + + if (action == E_CAL_COMPONENT_ALARM_PROCEDURE) + e_cal_component_remove_alarm (clone, (const char *)l->data); + } + } + + cal_obj_uid_list_free (uids); + } /* Strip X-LIC-ERROR stuff */ e_cal_component_strip_errors (clone); @@ -1164,7 +1187,7 @@ append_cal_attachments (EMsgComposer *composer, gboolean itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, - ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users) + ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users, gboolean strip_alarms) { EMsgComposer *composer; EComposerHeaderTable *table; @@ -1197,7 +1220,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, } /* Tidy up the comp */ - comp = comp_compliant (method, send_comp, client, zones); + comp = comp_compliant (method, send_comp, client, zones, strip_alarms); if (comp == NULL) goto cleanup; @@ -1312,7 +1335,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, gboolean retval = FALSE; /* Tidy up the comp */ - comp = comp_compliant (method, send_comp, client, zones); + comp = comp_compliant (method, send_comp, client, zones, TRUE); if (comp == NULL) goto cleanup; -- cgit v1.2.3 From fee5916b60c605ff5086d8fdc2a85c5ea21351f6 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Sat, 31 Jan 2009 19:03:12 +0000 Subject: Merge revisions 37108:37199 from trunk. svn path=/branches/kill-bonobo/; revision=37200 --- calendar/gui/itip-utils.c | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 17a5d97fb5..6b481d4a49 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -82,13 +82,13 @@ itip_addresses_get_default (void) } gboolean -itip_organizer_is_user (ECalComponent *comp, ECal *client) +itip_organizer_is_user_ex (ECalComponent *comp, ECal *client, gboolean skip_cap_test) { ECalComponentOrganizer organizer; const char *strip; gboolean user_org = FALSE; - if (!e_cal_component_has_organizer (comp) || e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_ORGANIZER)) + if (!e_cal_component_has_organizer (comp) || (!skip_cap_test && e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_ORGANIZER))) return FALSE; e_cal_component_get_organizer (comp, &organizer); @@ -115,6 +115,12 @@ itip_organizer_is_user (ECalComponent *comp, ECal *client) return user_org; } +gboolean +itip_organizer_is_user (ECalComponent *comp, ECal *client) +{ + return itip_organizer_is_user_ex (comp, client, FALSE); +} + gboolean itip_sentby_is_user (ECalComponent *comp) { @@ -858,7 +864,7 @@ comp_limit_attendees (ECalComponent *comp) continue; } - attendee = icalproperty_get_value_as_string (prop); + attendee = icalproperty_get_value_as_string_r (prop); if (!attendee) continue; @@ -1254,7 +1260,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, content_type = comp_content_type (comp, method); top_level = comp_toplevel_with_zones (method, comp, client, zones); - ical_string = icalcomponent_as_ical_string (top_level); + ical_string = icalcomponent_as_ical_string_r (top_level); if (e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_EVENT) { e_msg_composer_set_body (composer, ical_string, content_type); @@ -1358,7 +1364,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, e_destination_freev (destinations); top_level = comp_toplevel_with_zones (method, comp, client, zones); - ical_string = icalcomponent_as_ical_string (top_level); + ical_string = icalcomponent_as_ical_string_r (top_level); if (e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_EVENT){ @@ -1668,7 +1674,7 @@ itip_publish_comp (ECal *client, gchar *uri, gchar *username, } soup_message_set_flags (msg, SOUP_MESSAGE_NO_REDIRECT); - ical_string = icalcomponent_as_ical_string (toplevel); + ical_string = icalcomponent_as_ical_string_r (toplevel); soup_message_set_request (msg, "text/calendar", SOUP_MEMORY_TEMPORARY, ical_string, strlen (ical_string)); -- cgit v1.2.3 From e4afd3f9fb962ea1295a0657ec9f83a427829171 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 26 May 2009 23:21:02 -0400 Subject: Remove trailing whitespace, again. --- calendar/gui/itip-utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 30ad9822c7..ae822c9b9c 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -10,7 +10,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with the program; if not, see + * License along with the program; if not, see * * * Authors: -- cgit v1.2.3 From 948235c3d1076dbe6ed2e57a24c16a083bbd9f01 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Wed, 27 May 2009 10:29:19 -0400 Subject: Prefer GLib basic types over C types. --- calendar/gui/itip-utils.c | 98 +++++++++++++++++++++++------------------------ 1 file changed, 49 insertions(+), 49 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index bf270de0af..065434e4af 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -85,7 +85,7 @@ gboolean itip_organizer_is_user_ex (ECalComponent *comp, ECal *client, gboolean skip_cap_test) { ECalComponentOrganizer organizer; - const char *strip; + const gchar *strip; gboolean user_org = FALSE; if (!e_cal_component_has_organizer (comp) || (!skip_cap_test && e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_ORGANIZER))) @@ -97,7 +97,7 @@ itip_organizer_is_user_ex (ECalComponent *comp, ECal *client, gboolean skip_cap_ strip = itip_strip_mailto (organizer.value); if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_ORGANIZER_NOT_EMAIL_ADDRESS)) { - char *email = NULL; + gchar *email = NULL; if (e_cal_get_cal_address (client, &email, NULL) && !g_ascii_strcasecmp (email, strip)) { g_free (email); @@ -125,7 +125,7 @@ gboolean itip_sentby_is_user (ECalComponent *comp, ECal *client) { ECalComponentOrganizer organizer; - const char *strip; + const gchar *strip; gboolean user_sentby = FALSE; if (!e_cal_component_has_organizer (comp) ||e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_NO_ORGANIZER)) @@ -141,7 +141,7 @@ itip_sentby_is_user (ECalComponent *comp, ECal *client) } static ECalComponentAttendee * -get_attendee (GSList *attendees, char *address) +get_attendee (GSList *attendees, gchar *address) { GSList *l; @@ -160,7 +160,7 @@ get_attendee (GSList *attendees, char *address) } static ECalComponentAttendee * -get_attendee_if_attendee_sentby_is_user (GSList *attendees, char *address) +get_attendee_if_attendee_sentby_is_user (GSList *attendees, gchar *address) { GSList *l; @@ -175,8 +175,8 @@ get_attendee_if_attendee_sentby_is_user (GSList *attendees, char *address) return NULL; } -static char * -html_new_lines_for (const char *string) +static gchar * +html_new_lines_for (const gchar *string) { gchar **lines; gchar *joined; @@ -188,7 +188,7 @@ html_new_lines_for (const char *string) return joined; } -char * +gchar * itip_get_comp_attendee (ECalComponent *comp, ECal *client) { GSList *attendees; @@ -196,7 +196,7 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client) EAccount *a; EIterator *it; ECalComponentAttendee *attendee = NULL; - char *address = NULL; + gchar *address = NULL; e_cal_component_get_attendee_list (comp, &attendees); al = itip_addresses_get (); @@ -208,7 +208,7 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client) attendee = get_attendee (attendees, address); if (attendee) { - char *user_email = g_strdup (itip_strip_mailto (attendee->value)); + gchar *user_email = g_strdup (itip_strip_mailto (attendee->value)); e_cal_component_free_attendee_list (attendees); g_free (address); @@ -218,7 +218,7 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client) attendee = get_attendee_if_attendee_sentby_is_user (attendees, address); if (attendee) { - char *user_email = g_strdup (itip_strip_mailto (attendee->sentby)); + gchar *user_email = g_strdup (itip_strip_mailto (attendee->sentby)); e_cal_component_free_attendee_list (attendees); g_free (address); @@ -239,7 +239,7 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client) attendee = get_attendee (attendees, a->id->address); if (attendee) { - char *user_email = g_strdup (itip_strip_mailto (attendee->value)); + gchar *user_email = g_strdup (itip_strip_mailto (attendee->value)); e_cal_component_free_attendee_list (attendees); return user_email; @@ -249,7 +249,7 @@ itip_get_comp_attendee (ECalComponent *comp, ECal *client) check the 'sentby' fields of the attendees if we can find the account */ attendee = get_attendee_if_attendee_sentby_is_user (attendees, a->id->address); if (attendee) { - char *user_email = g_strdup (itip_strip_mailto (attendee->sentby)); + gchar *user_email = g_strdup (itip_strip_mailto (attendee->sentby)); e_cal_component_free_attendee_list (attendees); return user_email; @@ -278,10 +278,10 @@ itip_strip_mailto (const gchar *address) return address; } -static char * +static gchar * get_label (struct icaltimetype *tt) { - char buffer[1000]; + gchar buffer[1000]; struct tm tmp_tm; tmp_tm = icaltimetype_to_tm (tt); @@ -305,7 +305,7 @@ static void foreach_tzid_callback (icalparameter *param, gpointer data) { ItipUtilTZData *tz_data = data; - const char *tzid; + const gchar *tzid; icaltimezone *zone = NULL; icalcomponent *vtimezone_comp; @@ -330,7 +330,7 @@ foreach_tzid_callback (icalparameter *param, gpointer data) return; icalcomponent_add_component (tz_data->icomp, icalcomponent_new_clone (vtimezone_comp)); - g_hash_table_insert (tz_data->tzids, (char *)tzid, (char *)tzid); + g_hash_table_insert (tz_data->tzids, (gchar *)tzid, (gchar *)tzid); } static icalcomponent * @@ -364,7 +364,7 @@ comp_toplevel_with_zones (ECalComponentItipMethod method, ECalComponent *comp, E } static gboolean -users_has_attendee (GList *users, const char *address) +users_has_attendee (GList *users, const gchar *address) { GList *l; @@ -383,7 +383,7 @@ comp_from (ECalComponentItipMethod method, ECalComponent *comp) ECalComponentAttendee *attendee; GSList *attendees; gchar *from; - char *sender = NULL; + gchar *sender = NULL; switch (method) { case E_CAL_COMPONENT_METHOD_PUBLISH: @@ -436,7 +436,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, GPtrArray *array = NULL; EDestination *destination; gint len; - char *sender = NULL; + gchar *sender = NULL; union { gpointer *pdata; @@ -616,10 +616,10 @@ static gchar * comp_subject (ECalComponentItipMethod method, ECalComponent *comp) { ECalComponentText caltext; - const char *description, *prefix = NULL; + const gchar *description, *prefix = NULL; GSList *alist, *l; gchar *subject; - char *sender; + gchar *sender; ECalComponentAttendee *a = NULL; e_cal_component_get_summary (comp, &caltext); @@ -770,7 +770,7 @@ comp_description (ECalComponent *comp) { gchar *description; ECalComponentDateTime dt; - char *start = NULL, *end = NULL; + gchar *start = NULL, *end = NULL; switch (e_cal_component_get_vtype (comp)) { case E_CAL_COMPONENT_EVENT: @@ -852,11 +852,11 @@ comp_limit_attendees (ECalComponent *comp) prop != NULL; prop = icalcomponent_get_next_property (icomp, ICAL_ATTENDEE_PROPERTY)) { - char *attendee; - char *attendee_text; + gchar *attendee; + gchar *attendee_text; icalparameter *param; - const char *attendee_sentby; - char *attendee_sentby_text = NULL; + const gchar *attendee_sentby; + gchar *attendee_sentby_text = NULL; /* If we've already found something, just erase the rest */ if (found) { @@ -907,7 +907,7 @@ comp_sentby (ECalComponent *comp, ECal *client) { ECalComponentOrganizer organizer; GSList * attendees, *l; - char *user = NULL; + gchar *user = NULL; e_cal_component_get_organizer (comp, &organizer); if (!organizer.value) { @@ -919,7 +919,7 @@ comp_sentby (ECalComponent *comp, ECal *client) organizer.language = NULL; e_cal_component_set_organizer (comp, &organizer); - g_free ((char *) organizer.value); + g_free ((gchar *) organizer.value); return; } @@ -945,10 +945,10 @@ comp_sentby (ECalComponent *comp, ECal *client) e_cal_component_set_organizer (comp, &organizer); - g_free ((char *)organizer.value); - g_free ((char *)organizer.sentby); - g_free ((char *)organizer.cn); - g_free ((char *)organizer.language); + g_free ((gchar *)organizer.value); + g_free ((gchar *)organizer.sentby); + g_free ((gchar *)organizer.cn); + g_free ((gchar *)organizer.language); } } static ECalComponent * @@ -958,7 +958,7 @@ comp_minimal (ECalComponent *comp, gboolean attendee) icalcomponent *icomp, *icomp_clone; icalproperty *prop; ECalComponentOrganizer organizer; - const char *uid; + const gchar *uid; GSList *comments; struct icaltimetype itt; ECalComponentRange recur_id; @@ -1099,13 +1099,13 @@ comp_compliant (ECalComponentItipMethod method, ECalComponent *comp, ECal *clien ECalComponentAlarm *alarm; ECalComponentAlarmAction action = E_CAL_COMPONENT_ALARM_UNKNOWN; - alarm = e_cal_component_get_alarm (clone, (const char *)l->data); + alarm = e_cal_component_get_alarm (clone, (const gchar *)l->data); if (alarm) { e_cal_component_alarm_get_action (alarm, &action); e_cal_component_alarm_free (alarm); if (action == E_CAL_COMPONENT_ALARM_PROCEDURE) - e_cal_component_remove_alarm (clone, (const char *)l->data); + e_cal_component_remove_alarm (clone, (const gchar *)l->data); } } @@ -1200,7 +1200,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, EDestination **destinations; ECalComponent *comp = NULL; icalcomponent *top_level = NULL; - char *ical_string = NULL; + gchar *ical_string = NULL; gchar *from = NULL; gchar *content_type = NULL; gchar *subject = NULL; @@ -1337,7 +1337,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, GList *users = NULL; gchar *from; gchar *subject; - char *ical_string = NULL; + gchar *ical_string = NULL; gboolean retval = FALSE; /* Tidy up the comp */ @@ -1369,12 +1369,12 @@ reply_to_calendar_comp (ECalComponentItipMethod method, if (e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_EVENT){ GString *body; - char *orig_from = NULL; - const char *description = NULL; - char *subject = NULL; - const char *location = NULL; - char *time = NULL; - char *html_description = NULL; + gchar *orig_from = NULL; + const gchar *description = NULL; + gchar *subject = NULL; + const gchar *location = NULL; + gchar *time = NULL; + gchar *html_description = NULL; GSList *text_list = NULL; ECalComponentOrganizer organizer; ECalComponentText text; @@ -1518,9 +1518,9 @@ itip_publish_begin (ECalComponent *pub_comp, ECal *client, } static void -fb_sort (struct icalperiodtype *ipt, int fb_count) +fb_sort (struct icalperiodtype *ipt, gint fb_count) { - int i,j; + gint i,j; if (ipt == NULL || fb_count == 0) return; @@ -1549,9 +1549,9 @@ comp_fb_normalize (icalcomponent *icomp) { icalcomponent *iclone; icalproperty *prop, *p; - const char *uid, *comment; + const gchar *uid, *comment; struct icaltimetype itt; - int fb_count, i = 0, j; + gint fb_count, i = 0, j; struct icalperiodtype *ipt; iclone = icalcomponent_new (ICAL_VFREEBUSY_COMPONENT); @@ -1638,7 +1638,7 @@ itip_publish_comp (ECal *client, gchar *uri, gchar *username, SoupSession *session; SoupMessage *msg; SoupURI *real_uri; - char *ical_string = NULL; + gchar *ical_string = NULL; toplevel = e_cal_util_new_top_level (); icalcomponent_set_method (toplevel, ICAL_METHOD_PUBLISH); -- cgit v1.2.3 From 14f8eee012382f04090ea9277e9567d5f32e8bf0 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Thu, 28 May 2009 13:06:29 -0400 Subject: Whitespace cleanup. --- calendar/gui/itip-utils.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 065434e4af..9056650ea8 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -94,20 +94,20 @@ itip_organizer_is_user_ex (ECalComponent *comp, ECal *client, gboolean skip_cap_ e_cal_component_get_organizer (comp, &organizer); if (organizer.value != NULL) { - strip = itip_strip_mailto (organizer.value); + strip = itip_strip_mailto (organizer.value); - if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_ORGANIZER_NOT_EMAIL_ADDRESS)) { - gchar *email = NULL; + if (e_cal_get_static_capability (client, CAL_STATIC_CAPABILITY_ORGANIZER_NOT_EMAIL_ADDRESS)) { + gchar *email = NULL; - if (e_cal_get_cal_address (client, &email, NULL) && !g_ascii_strcasecmp (email, strip)) { + if (e_cal_get_cal_address (client, &email, NULL) && !g_ascii_strcasecmp (email, strip)) { g_free (email); - return TRUE; + return TRUE; } g_free (email); - return FALSE; - } + return FALSE; + } user_org = e_account_list_find(itip_addresses_get(), E_ACCOUNT_FIND_ID_ADDRESS, strip) != NULL; } @@ -436,7 +436,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, GPtrArray *array = NULL; EDestination *destination; gint len; - gchar *sender = NULL; + gchar *sender = NULL; union { gpointer *pdata; @@ -1386,13 +1386,13 @@ reply_to_calendar_comp (ECalComponentItipMethod method, if (text_list){ ECalComponentText text = *((ECalComponentText *)text_list->data); - if (text.value) - description = text.value; - else - description = ""; - } else { - description = ""; - } + if (text.value) + description = text.value; + else + description = ""; + } else { + description = ""; + } e_cal_component_free_text_list (text_list); @@ -1502,8 +1502,8 @@ itip_publish_begin (ECalComponent *pub_comp, ECal *client, icomp_clone = e_cal_component_get_icalcomponent (*clone); for (prop = icalcomponent_get_first_property (icomp, ICAL_FREEBUSY_PROPERTY); - prop != NULL; - prop = icalcomponent_get_next_property (icomp, + prop != NULL; + prop = icalcomponent_get_next_property (icomp, ICAL_FREEBUSY_PROPERTY)) { icalproperty *p; -- cgit v1.2.3 From 433eac7844481b8ceda0bae8bf08f6bb623185b0 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Mon, 1 Jun 2009 19:09:19 -0400 Subject: More code cleanup. --- calendar/gui/itip-utils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 9056650ea8..2287f59248 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -654,7 +654,7 @@ comp_subject (ECalComponentItipMethod method, ECalComponent *comp) sender = itip_get_comp_attendee (comp, NULL); if (sender) { - for (l = alist; l != NULL ; l = l->next) { + for (l = alist; l != NULL; l = l->next) { a = l->data; if ((sender && *sender) && (g_ascii_strcasecmp (itip_strip_mailto (a->value), sender) || (a->sentby && g_ascii_strcasecmp (itip_strip_mailto (a->sentby), sender)))) break; @@ -1160,7 +1160,7 @@ append_cal_attachments (EMsgComposer *composer, struct CalMimeAttach *mime_attach; GSList *l; - for (l = attach_list; l ; l = l->next) { + for (l = attach_list; l; l = l->next) { CamelMimePart *attachment; mime_attach = (struct CalMimeAttach *) l->data; -- cgit v1.2.3 From 374bd42f69aca2e132fd854c9619f3d7491f1f96 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Sun, 12 Jul 2009 23:33:07 -0400 Subject: Fix excessive whitespace. --- calendar/gui/itip-utils.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 2287f59248..10eda35811 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -300,7 +300,6 @@ typedef struct { icalcomponent *zones; } ItipUtilTZData; - static void foreach_tzid_callback (icalparameter *param, gpointer data) { @@ -411,7 +410,6 @@ comp_from (ECalComponentItipMethod method, ECalComponent *comp) } return g_strdup (itip_strip_mailto (organizer.value)); - default: if (!e_cal_component_has_attendees (comp)) return NULL; @@ -1396,22 +1394,18 @@ reply_to_calendar_comp (ECalComponentItipMethod method, e_cal_component_free_text_list (text_list); - e_cal_component_get_summary (comp, &text); if (text.value) subject = g_strdup (text.value); - e_cal_component_get_organizer (comp, &organizer); if (organizer.value) orig_from = g_strdup (itip_strip_mailto (organizer.value)); - e_cal_component_get_location (comp, &location); if (!location) location = "Unspecified"; - e_cal_component_get_dtstart (comp, &dtstart); if (dtstart.value) { start_zone = icaltimezone_get_builtin_timezone_from_tzid (dtstart.tzid); @@ -1427,7 +1421,6 @@ reply_to_calendar_comp (ECalComponentItipMethod method, time = g_strdup (ctime (&start)); } - body = g_string_new ("



______ Original Appointment ______

"); if (orig_from && *orig_from) -- cgit v1.2.3 From fa360fde289f9b850191f89059d1a5e6d67c07c7 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Sat, 18 Jul 2009 14:07:42 -0400 Subject: More whitespace cleanup. --- calendar/gui/itip-utils.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 10eda35811..5acabdbc25 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -496,7 +496,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, case E_CAL_COMPONENT_METHOD_REPLY: - if (reply_all){ + if (reply_all) { e_cal_component_get_attendee_list (comp, &attendees); len = g_slist_length (attendees); @@ -567,7 +567,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, if (att->cutype != ICAL_CUTYPE_INDIVIDUAL && att->cutype != ICAL_CUTYPE_GROUP) continue; - if (!g_ascii_strcasecmp (itip_strip_mailto (att->value), sender) || (att->sentby && !g_ascii_strcasecmp (itip_strip_mailto (att->sentby), sender))){ + if (!g_ascii_strcasecmp (itip_strip_mailto (att->value), sender) || (att->sentby && !g_ascii_strcasecmp (itip_strip_mailto (att->sentby), sender))) { if (!(att->delfrom && *att->delfrom)) break; @@ -583,7 +583,7 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, break; case E_CAL_COMPONENT_METHOD_PUBLISH: - if(users) { + if (users) { GList *list; array = g_ptr_array_new (); @@ -1364,7 +1364,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, top_level = comp_toplevel_with_zones (method, comp, client, zones); ical_string = icalcomponent_as_ical_string_r (top_level); - if (e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_EVENT){ + if (e_cal_component_get_vtype (comp) == E_CAL_COMPONENT_EVENT) { GString *body; gchar *orig_from = NULL; @@ -1382,7 +1382,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, e_cal_component_get_description_list (comp, &text_list); - if (text_list){ + if (text_list) { ECalComponentText text = *((ECalComponentText *)text_list->data); if (text.value) description = text.value; @@ -1525,7 +1525,7 @@ fb_sort (struct icalperiodtype *ipt, gint fb_count) if (icaltime_compare (ipt[i].start, ipt[j].start) < 0) continue; - if (icaltime_compare (ipt[i].start, ipt[j].start) == 0){ + if (icaltime_compare (ipt[i].start, ipt[j].start) == 0) { if (icaltime_compare (ipt[i].end, ipt[j].start) < 0) continue; -- cgit v1.2.3 From 854c2cd5c84a7c6a38ecf2fc86efb6e474aa32fa Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Thu, 30 Jul 2009 11:31:14 +0200 Subject: Bug #273535 - Meeting request with attachments has bogus CID value --- calendar/gui/itip-utils.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 5acabdbc25..cd0a64f1c8 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1167,6 +1167,8 @@ append_cal_attachments (EMsgComposer *composer, camel_mime_part_set_content ( attachment, mime_attach->encoded_data, mime_attach->length, mime_attach->content_type); + if (mime_attach->content_id) + camel_mime_part_set_content_id (attachment, mime_attach->content_id); if (mime_attach->filename != NULL) camel_mime_part_set_filename ( attachment, mime_attach->filename); @@ -1184,9 +1186,13 @@ append_cal_attachments (EMsgComposer *composer, g_free (mime_attach->filename); g_free (mime_attach->content_type); + g_free (mime_attach->content_id); g_free (mime_attach->description); g_free (mime_attach->encoded_data); + g_free (mime_attach); } + + g_slist_free (attach_list); } gboolean -- cgit v1.2.3 From 5e5e1de764de6b705c12275dc652b1a36ba98fdd Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Mon, 27 Jul 2009 17:34:13 +0200 Subject: Bug #420513 - Be able to notify about meeting only new attendees --- calendar/gui/itip-utils.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index cd0a64f1c8..08389aff08 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -35,6 +35,7 @@ #include "calendar-config.h" #include "itip-utils.h" #include +#include "dialogs/comp-editor-util.h" #include #include @@ -427,7 +428,7 @@ comp_from (ECalComponentItipMethod method, ECalComponent *comp) } static EDestination ** -comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, gboolean reply_all) +comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, gboolean reply_all, const GSList *only_attendees) { ECalComponentOrganizer organizer; GSList *attendees, *l; @@ -482,6 +483,8 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, else if (att->status == ICAL_PARTSTAT_DELEGATED && (att->delto && *att->delto) && !(att->rsvp) && method == E_CAL_COMPONENT_METHOD_REQUEST) continue; + else if (only_attendees && !comp_editor_have_in_new_attendees_lst (only_attendees, itip_strip_mailto (att->value))) + continue; destination = e_destination_new (); if (att->cn != NULL) @@ -513,6 +516,8 @@ comp_to_list (ECalComponentItipMethod method, ECalComponent *comp, GList *users, if (att->cutype != ICAL_CUTYPE_INDIVIDUAL && att->cutype != ICAL_CUTYPE_GROUP) continue; + else if (only_attendees && !comp_editor_have_in_new_attendees_lst (only_attendees, itip_strip_mailto (att->value))) + continue; destination = e_destination_new (); if (att->cn != NULL) @@ -1197,7 +1202,8 @@ append_cal_attachments (EMsgComposer *composer, gboolean itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, - ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users, gboolean strip_alarms) + ECal *client, icalcomponent *zones, GSList *attachments_list, GList *users, + gboolean strip_alarms, gboolean only_new_attendees) { EMsgComposer *composer; EComposerHeaderTable *table; @@ -1236,7 +1242,7 @@ itip_send_comp (ECalComponentItipMethod method, ECalComponent *send_comp, goto cleanup; /* Recipients */ - destinations = comp_to_list (method, comp, users, FALSE); + destinations = comp_to_list (method, comp, users, FALSE, only_new_attendees ? g_object_get_data (G_OBJECT (send_comp), "new-attendees") : NULL); if (method != E_CAL_COMPONENT_METHOD_PUBLISH) { if (destinations == NULL) { /* We sent them all via the server */ @@ -1350,7 +1356,7 @@ reply_to_calendar_comp (ECalComponentItipMethod method, goto cleanup; /* Recipients */ - destinations = comp_to_list (method, comp, users, reply_all); + destinations = comp_to_list (method, comp, users, reply_all, NULL); /* Subject information */ subject = comp_subject (method, comp); -- cgit v1.2.3 From cdd06c393d2c6dd0b5716a354aecc92c8457dc4d Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Mon, 27 Jul 2009 20:55:30 +0200 Subject: Compiler warning fixes (as part of bug #424078) --- calendar/gui/itip-utils.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'calendar/gui/itip-utils.c') diff --git a/calendar/gui/itip-utils.c b/calendar/gui/itip-utils.c index 08389aff08..38fcb46bb7 100644 --- a/calendar/gui/itip-utils.c +++ b/calendar/gui/itip-utils.c @@ -1345,8 +1345,8 @@ reply_to_calendar_comp (ECalComponentItipMethod method, ECalComponent *comp = NULL; icalcomponent *top_level = NULL; GList *users = NULL; - gchar *from; - gchar *subject; + gchar *from = NULL; + gchar *subject = NULL; gchar *ical_string = NULL; gboolean retval = FALSE; -- cgit v1.2.3