aboutsummaryrefslogtreecommitdiffstats
path: root/calendar
diff options
context:
space:
mode:
Diffstat (limited to 'calendar')
-rw-r--r--calendar/ChangeLog26
-rw-r--r--calendar/gui/alarm-notify/alarm-notify.c2
-rw-r--r--calendar/gui/calendar-offline-handler.c6
-rw-r--r--calendar/gui/comp-editor-factory.c2
-rw-r--r--calendar/gui/dialogs/copy-source-dialog.c8
-rw-r--r--calendar/gui/e-itip-control.c6
-rw-r--r--calendar/gui/e-tasks.c2
-rw-r--r--calendar/gui/gnome-cal.c4
-rw-r--r--calendar/importers/icalendar-importer.c12
9 files changed, 45 insertions, 23 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog
index 2ba98c0ab9..f9031015b4 100644
--- a/calendar/ChangeLog
+++ b/calendar/ChangeLog
@@ -1,3 +1,29 @@
+2003-11-26 Hans Petter Jansson <hpj@ximian.com>
+
+ * gui/calendar-offline-handler.c (backend_go_offline): e_cal_new () ->
+ e_cal_new_from_uri ().
+ (backend_go_online): Ditto.
+ (calendar_offline_handler_init): Ditto.
+
+ * gui/comp-editor-factory.c (open_client): Ditto.
+
+ * gui/e-itip-control.c (start_calendar_server): Ditto.
+ (object_requested_cb): Ditto.
+
+ * gui/e-tasks.c (e_tasks_add_todo_uri): Ditto.
+
+ * gui/gnome-cal.c (gnome_calendar_construct): Ditto.
+ (gnome_calendar_add_event_uri): Ditto.
+
+ * gui/alarm-notify/alarm-notify.c (alarm_notify_add_calendar): Ditto.
+
+ * importers/icalendar-importer.c (load_file_fn): Ditto.
+ (vcal_load_file_fn): Ditto.
+ (gnome_calendar_import_data_fn): Ditto.
+
+ * gui/dialogs/copy-source-dialog.c (copy_source): Pass sources to
+ e_cal_new ().
+
2003-11-24 Rodrigo Moya <rodrigo@ximian.com>
* gui/dialogs/copy-source-dialog.c (copy_source): use the correct
diff --git a/calendar/gui/alarm-notify/alarm-notify.c b/calendar/gui/alarm-notify/alarm-notify.c
index fa43e2bab6..bb34ba8ef4 100644
--- a/calendar/gui/alarm-notify/alarm-notify.c
+++ b/calendar/gui/alarm-notify/alarm-notify.c
@@ -279,7 +279,7 @@ alarm_notify_add_calendar (AlarmNotify *an, const char *str_uri, gboolean load_a
if (g_hash_table_lookup (priv->uri_client_hash, str_uri))
return;
- client = e_cal_new (str_uri, CALOBJ_TYPE_EVENT);
+ client = e_cal_new_from_uri (str_uri, CALOBJ_TYPE_EVENT);
if (client) {
if (e_cal_open (client, FALSE, NULL)) {
diff --git a/calendar/gui/calendar-offline-handler.c b/calendar/gui/calendar-offline-handler.c
index 55bca89cc7..89a7aab36e 100644
--- a/calendar/gui/calendar-offline-handler.c
+++ b/calendar/gui/calendar-offline-handler.c
@@ -183,7 +183,7 @@ backend_go_offline (gpointer data, gpointer user_data)
gboolean success;
GError *error = NULL;
- client = e_cal_new (uri, CALOBJ_TYPE_ANY);
+ client = e_cal_new_from_uri (uri, CALOBJ_TYPE_ANY);
g_signal_connect (client, "cal_opened", G_CALLBACK (backend_cal_opened_offline), offline_handler);
success = e_cal_open (client, TRUE, &error);
if (!success) {
@@ -204,7 +204,7 @@ backend_go_online (gpointer data, gpointer user_data)
gboolean success;
GError *error = NULL;
- client = e_cal_new (uri, CALOBJ_TYPE_ANY);
+ client = e_cal_new_from_uri (uri, CALOBJ_TYPE_ANY);
g_signal_connect (G_OBJECT (client), "cal_opened",
G_CALLBACK (backend_cal_opened_online), offline_handler);
success = e_cal_open (client, TRUE, &error);
@@ -327,7 +327,7 @@ calendar_offline_handler_init (CalendarOfflineHandler *offline_handler)
offline_handler->priv = priv;
/* FIXME: what URI to use? */
- priv->client = e_cal_new ("", CALOBJ_TYPE_ANY);
+ priv->client = e_cal_new_from_uri ("", CALOBJ_TYPE_ANY);
priv->listener_interface = CORBA_OBJECT_NIL;
priv->is_offline = FALSE;
}
diff --git a/calendar/gui/comp-editor-factory.c b/calendar/gui/comp-editor-factory.c
index d85a2a0f97..a50b135f90 100644
--- a/calendar/gui/comp-editor-factory.c
+++ b/calendar/gui/comp-editor-factory.c
@@ -494,7 +494,7 @@ open_client (CompEditorFactory *factory, const char *uristr)
priv = factory->priv;
- client = e_cal_new (uristr, CALOBJ_TYPE_ANY);
+ client = e_cal_new_from_uri (uristr, CALOBJ_TYPE_ANY);
if (!client)
return NULL;
diff --git a/calendar/gui/dialogs/copy-source-dialog.c b/calendar/gui/dialogs/copy-source-dialog.c
index feec6b8497..a1d51e7f74 100644
--- a/calendar/gui/dialogs/copy-source-dialog.c
+++ b/calendar/gui/dialogs/copy-source-dialog.c
@@ -63,9 +63,7 @@ copy_source (CopySourceDialogData *csdd)
return FALSE;
/* open the source */
- uri = e_source_get_uri (csdd->orig_source);
- source_client = e_cal_new (uri, csdd->obj_type);
- g_free (uri);
+ source_client = e_cal_new (csdd->orig_source, csdd->obj_type);
if (!e_cal_open (source_client, TRUE, NULL)) {
g_object_unref (source_client);
g_warning (G_STRLOC ": Could not open source");
@@ -73,9 +71,7 @@ copy_source (CopySourceDialogData *csdd)
}
/* open the destination */
- uri = e_source_get_uri (dest_source);
- dest_client = e_cal_new (uri, csdd->obj_type);
- g_free (uri);
+ dest_client = e_cal_new (dest_source, csdd->obj_type);
if (!e_cal_open (dest_client, FALSE, NULL)) {
g_object_unref (dest_client);
g_object_unref (source_client);
diff --git a/calendar/gui/e-itip-control.c b/calendar/gui/e-itip-control.c
index 95341b1fdf..5819daa7d9 100644
--- a/calendar/gui/e-itip-control.c
+++ b/calendar/gui/e-itip-control.c
@@ -135,7 +135,7 @@ start_calendar_server (EItipControl *itip, char *uri)
ECal *client;
GError *error = NULL;
- client = e_cal_new (uri, CALOBJ_TYPE_EVENT);
+ client = e_cal_new_from_uri (uri, CALOBJ_TYPE_EVENT);
if (!e_cal_open (client, TRUE, &error)) {
g_warning (_("start_calendar_server(): %s"), error->message);
@@ -2209,11 +2209,11 @@ object_requested_cb (GtkHTML *html, GtkHTMLEmbedded *eb, gpointer data)
switch (vtype) {
case E_CAL_COMPONENT_EVENT:
- context->client = e_cal_new ("", CALOBJ_TYPE_EVENT);
+ context->client = e_cal_new_from_uri ("", CALOBJ_TYPE_EVENT);
success = start_default_server (itip, context->client, FALSE);
break;
case E_CAL_COMPONENT_TODO:
- context->client = e_cal_new ("", CALOBJ_TYPE_TODO);
+ context->client = e_cal_new_from_uri ("", CALOBJ_TYPE_TODO);
success = start_default_server (itip, context->client, TRUE);
break;
default:
diff --git a/calendar/gui/e-tasks.c b/calendar/gui/e-tasks.c
index 011ac03f4c..df4c3f82a4 100644
--- a/calendar/gui/e-tasks.c
+++ b/calendar/gui/e-tasks.c
@@ -850,7 +850,7 @@ e_tasks_add_todo_uri (ETasks *tasks, const char *str_uri)
if (client)
return TRUE;
- client = e_cal_new (str_uri, CALOBJ_TYPE_TODO);
+ client = e_cal_new_from_uri (str_uri, CALOBJ_TYPE_TODO);
g_hash_table_insert (priv->clients, g_strdup (str_uri), client);
priv->clients_list = g_list_prepend (priv->clients_list, client);
diff --git a/calendar/gui/gnome-cal.c b/calendar/gui/gnome-cal.c
index 7ecabf8c46..9bc7dbc951 100644
--- a/calendar/gui/gnome-cal.c
+++ b/calendar/gui/gnome-cal.c
@@ -2032,7 +2032,7 @@ gnome_calendar_construct (GnomeCalendar *gcal)
/*
* TaskPad Folder Client.
*/
- priv->task_pad_client = e_cal_new ("", CALOBJ_TYPE_TODO); /* FIXME: use default tasks */
+ priv->task_pad_client = e_cal_new_from_uri ("", CALOBJ_TYPE_TODO); /* FIXME: use default tasks */
if (!priv->task_pad_client)
return NULL;
@@ -2161,7 +2161,7 @@ gnome_calendar_add_event_uri (GnomeCalendar *gcal, const char *str_uri)
if (client)
return TRUE;
- client = e_cal_new (str_uri, CALOBJ_TYPE_EVENT);
+ client = e_cal_new_from_uri (str_uri, CALOBJ_TYPE_EVENT);
g_hash_table_insert (priv->clients, g_strdup (str_uri), client);
priv->clients_list = g_list_prepend (priv->clients_list, client);
diff --git a/calendar/importers/icalendar-importer.c b/calendar/importers/icalendar-importer.c
index 70906e1578..21e442e628 100644
--- a/calendar/importers/icalendar-importer.c
+++ b/calendar/importers/icalendar-importer.c
@@ -376,9 +376,9 @@ load_file_fn (EvolutionImporter *importer,
/* create ECal's */
if (!ici->client)
- ici->client = e_cal_new (real_uri, CALOBJ_TYPE_EVENT);
+ ici->client = e_cal_new_from_uri (real_uri, CALOBJ_TYPE_EVENT);
if (!ici->tasks_client)
- ici->tasks_client = e_cal_new ("", CALOBJ_TYPE_TODO); /* FIXME */
+ ici->tasks_client = e_cal_new_from_uri ("", CALOBJ_TYPE_TODO); /* FIXME */
if (e_cal_open (ici->client, TRUE, NULL)
&& e_cal_open (ici->tasks_client, FALSE, NULL)) {
@@ -528,9 +528,9 @@ vcal_load_file_fn (EvolutionImporter *importer,
/* create ECal's */
if (!ici->client)
- ici->client = e_cal_new (real_uri, CALOBJ_TYPE_EVENT);
+ ici->client = e_cal_new_from_uri (real_uri, CALOBJ_TYPE_EVENT);
if (!ici->tasks_client)
- ici->tasks_client = e_cal_new ("", CALOBJ_TYPE_TODO);
+ ici->tasks_client = e_cal_new_from_uri ("", CALOBJ_TYPE_TODO);
if (e_cal_open (ici->client, TRUE, NULL)
&& e_cal_open (ici->tasks_client, FALSE, NULL)) {
@@ -616,13 +616,13 @@ gnome_calendar_import_data_fn (EvolutionIntelligentImporter *ii,
/* Try to open the default calendar & tasks folders. */
if (ici->do_calendar) {
- calendar_client = e_cal_new ("", CALOBJ_TYPE_EVENT); /* FIXME: use default folder */
+ calendar_client = e_cal_new_from_uri ("", CALOBJ_TYPE_EVENT); /* FIXME: use default folder */
if (!e_cal_open (calendar_client, FALSE, NULL))
goto out;
}
if (ici->do_tasks) {
- tasks_client = e_cal_new ("", CALOBJ_TYPE_TODO); /* FIXME: use default folder */
+ tasks_client = e_cal_new_from_uri ("", CALOBJ_TYPE_TODO); /* FIXME: use default folder */
if (!e_cal_open (tasks_client, FALSE, NULL))
goto out;
}