diff options
author | Harish Krishnaswamy <kharish@novell.com> | 2006-06-19 19:25:01 +0800 |
---|---|---|
committer | Harish Krishnaswamy <kharish@src.gnome.org> | 2006-06-19 19:25:01 +0800 |
commit | ff6bb90a969c201e06a2abbf1852b760331f7c32 (patch) | |
tree | 7b2894bdb00e3d2cfc13ccaff43582cef9ed98f0 /calendar | |
parent | 14748fdd0af022af5e73d38f217b2897263ffdcb (diff) | |
download | gsoc2013-evolution-ff6bb90a969c201e06a2abbf1852b760331f7c32.tar.gz gsoc2013-evolution-ff6bb90a969c201e06a2abbf1852b760331f7c32.tar.zst gsoc2013-evolution-ff6bb90a969c201e06a2abbf1852b760331f7c32.zip |
Remove GroupWise from the Calendar ESource Groups as it supports a single
2006-06-19 Harish Krishnaswamy <kharish@novell.com>
* gui/dialogs/calendar-setup.c: (calendar_setup_edit_calendar):
Remove GroupWise from the Calendar ESource Groups as it supports
a single calendar only.
svn path=/trunk/; revision=32173
Diffstat (limited to 'calendar')
-rw-r--r-- | calendar/ChangeLog | 6 | ||||
-rw-r--r-- | calendar/gui/dialogs/calendar-setup.c | 21 |
2 files changed, 26 insertions, 1 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 3328f2bf44..46b82d2bd0 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,5 +1,11 @@ 2006-06-19 Harish Krishnaswamy <kharish@novell.com> + * gui/dialogs/calendar-setup.c: (calendar_setup_edit_calendar): + Remove GroupWise from the Calendar ESource Groups as it supports + a single calendar only. + +2006-06-19 Harish Krishnaswamy <kharish@novell.com> + * gui/dialogs/comp-editor.c (fill_widgets): Free GSList and its data after calling e_cal_component_get_attachment_list. diff --git a/calendar/gui/dialogs/calendar-setup.c b/calendar/gui/dialogs/calendar-setup.c index 4c79a1c34c..755f81a2c9 100644 --- a/calendar/gui/dialogs/calendar-setup.c +++ b/calendar/gui/dialogs/calendar-setup.c @@ -427,12 +427,31 @@ calendar_setup_edit_calendar (struct _GtkWindow *parent, ESource *source, ESourc e_source_set_color (sdialog->source, color); } else { GConfClient *gconf; - GSList *l; + GSList *l, *ptr, *temp = NULL; sdialog->source = e_source_new ("", ""); gconf = gconf_client_get_default (); sdialog->source_list = e_source_list_new_for_gconf (gconf, "/apps/evolution/calendar/sources"); l = e_source_list_peek_groups (sdialog->source_list); + /* Skip GW as it supports only one calendar */ + ptr = l; + if (!strncmp (e_source_group_peek_base_uri ((ESourceGroup *)ptr->data), + "groupwise://", 12 )) { + l = l->next; + g_object_unref (ptr->data); + g_slist_free_1 (ptr); + } + for (ptr=l; ptr->next;) { + if (!strncmp (e_source_group_peek_base_uri ((ESourceGroup *)ptr->next->data), + "groupwise://", 12 )) { + temp = ptr->next; + ptr->next = temp->next; + g_object_unref (temp->data); + g_slist_free_1 (temp); + } else { + ptr = ptr->next; + } + } sdialog->menu_source_groups = g_slist_copy(l); sdialog->source_group = (ESourceGroup *)sdialog->menu_source_groups->data; |