From 0bdbb230d227325cc474ca1cfb5215a2edd78ae2 Mon Sep 17 00:00:00 2001 From: Rodrigo Moya Date: Tue, 11 May 2004 22:05:03 +0000 Subject: get error information from the call to e_cal_receive_objects, and use that 2004-05-11 Rodrigo Moya * gui/e-itip-control.c (update_item): get error information from the call to e_cal_receive_objects, and use that as the error message. svn path=/trunk/; revision=25862 --- calendar/gui/e-itip-control.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'calendar/gui/e-itip-control.c') diff --git a/calendar/gui/e-itip-control.c b/calendar/gui/e-itip-control.c index 0cc1b06cd9..13bce78ec9 100644 --- a/calendar/gui/e-itip-control.c +++ b/calendar/gui/e-itip-control.c @@ -1740,6 +1740,7 @@ update_item (EItipControl *itip) icalproperty *prop; icalcomponent *clone; GtkWidget *dialog; + GError *error = NULL; priv = itip->priv; @@ -1761,9 +1762,9 @@ update_item (EItipControl *itip) icalcomponent_add_component (priv->top_level, clone); icalcomponent_set_method (priv->top_level, priv->method); - /* FIXME Better error dialog */ - if (!e_cal_receive_objects (priv->current_ecal, priv->top_level, NULL)) { - dialog = gnome_warning_dialog (_("Calendar file could not be updated!\n")); + if (!e_cal_receive_objects (priv->current_ecal, priv->top_level, &error)) { + dialog = gnome_warning_dialog (error->message); + g_error_free (error); } else { dialog = gnome_ok_dialog (_("Update complete\n")); } -- cgit v1.2.3