From 3022554239b4f9ee31e622048a849a33a1ea54d5 Mon Sep 17 00:00:00 2001 From: Rodrigo Moya Date: Tue, 23 Dec 2003 12:25:21 +0000 Subject: renamed from *_uri, to work with ESource's rather than with plain URIs. 2003-12-22 Rodrigo Moya * gui/gnome-cal.[ch] (gnome_calendar_add_event_source, gnome_calendar_remove_event_source): renamed from *_uri, to work with ESource's rather than with plain URIs. (gnome_calendar_set_default_source): ditto. * gui/control-factory.c (set_prop): * gui/calendar-component.c (add_uri_for_source, remove_uri_for_source, update_uri_for_primary_selection): use sources instead of uris with the GnomeCalendar widget. svn path=/trunk/; revision=24005 --- calendar/gui/control-factory.c | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'calendar/gui/control-factory.c') diff --git a/calendar/gui/control-factory.c b/calendar/gui/control-factory.c index 58436ec841..b114300b5a 100644 --- a/calendar/gui/control-factory.c +++ b/calendar/gui/control-factory.c @@ -118,6 +118,8 @@ set_prop (BonoboPropertyBag *bag, GnomeCalendar *gcal; char *string; GnomeCalendarViewType view; + ESource *source; + ESourceGroup *group; BonoboControl *control = user_data; gcal = (GnomeCalendar *) bonobo_control_get_widget (control); @@ -125,7 +127,12 @@ set_prop (BonoboPropertyBag *bag, switch (arg_id) { case PROPERTY_CALENDAR_URI_IDX: string = BONOBO_ARG_GET_STRING (arg); - if (gnome_calendar_add_event_uri (gcal, string)) { + + group = e_source_group_new ("", string); + source = e_source_new ("", ""); + e_source_set_group (source, group); + + if (gnome_calendar_add_event_source (gcal, source)) { calendar_control_sensitize_calendar_commands (control, gcal, TRUE); } else { char *msg; @@ -136,6 +143,10 @@ set_prop (BonoboPropertyBag *bag, GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (gcal)))); g_free (msg); } + + g_object_unref (source); + g_object_unref (group); + break; case PROPERTY_CALENDAR_VIEW_IDX: -- cgit v1.2.3