aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-calendar-view.c
diff options
context:
space:
mode:
authorAshish Shrivastava <shashish@novell.com>2008-11-03 20:10:48 +0800
committerAkhil Laddha <lakhil@src.gnome.org>2008-11-03 20:10:48 +0800
commit26fe8fb76ea445c87fd72997f97e7c4950b53bd1 (patch)
tree76ff236dcf412c1e52da7607bbfa3b4d70afd561 /calendar/gui/e-calendar-view.c
parentc495bcad905e857b01f5d61c160f9897942d3394 (diff)
downloadgsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.tar
gsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.tar.gz
gsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.tar.bz2
gsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.tar.lz
gsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.tar.xz
gsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.tar.zst
gsoc2013-evolution-26fe8fb76ea445c87fd72997f97e7c4950b53bd1.zip
** Fix for bug #559086
2008-11-03 Ashish Shrivastava <shashish@novell.com> ** Fix for bug #559086 * Most of the calendar errors are now non-intrusive * calendar.error.xml: Added a new error message for non-intrusive backend_died. * apps_evolution_calendar.schemas.in: * calendar-commands.c: Added new verb for help debug message (help_debug): * gnome-cal.c: Support for non-intrusive error. (client_cal_opened_cb), Define fash table and accessing errors: * e-calendar-view.c: (error_response): (e_calendar_utils_show_error_silent), (e_calendar_utils_show_info_silent): * e-calendar-view.h: * calendar-component.c: Added EActivityHandler and ELogger: (calendar_component_peek_activity_handler), (calendar_component_show_logger): * calendar-component.h: svn path=/trunk/; revision=36727
Diffstat (limited to 'calendar/gui/e-calendar-view.c')
-rw-r--r--calendar/gui/e-calendar-view.c33
1 files changed, 33 insertions, 0 deletions
diff --git a/calendar/gui/e-calendar-view.c b/calendar/gui/e-calendar-view.c
index c58ceea2d6..b1c5819c35 100644
--- a/calendar/gui/e-calendar-view.c
+++ b/calendar/gui/e-calendar-view.c
@@ -2411,3 +2411,36 @@ draw_curved_rectangle (cairo_t *cr, double x0, double y0,
}
cairo_close_path (cr);
}
+
+static void
+error_response(GtkWidget *widget, gint response, void *data)
+{
+ if (response == GTK_RESPONSE_DELETE_EVENT)
+ gtk_widget_destroy(widget);
+ else if (response == GTK_RESPONSE_OK)
+ gtk_widget_destroy(widget);
+}
+
+void
+e_calendar_utils_show_error_silent (GtkWidget *widget)
+{
+ EActivityHandler *handler = calendar_component_peek_activity_handler (calendar_component_peek ());
+
+ if(!g_object_get_data ((GObject *) widget, "response-handled")) {
+ g_signal_connect(widget, "response", G_CALLBACK(error_response), NULL);
+ }
+
+ e_activity_handler_make_error (handler, "calendar", E_LOG_ERROR, widget);
+}
+
+void
+e_calendar_utils_show_info_silent (GtkWidget *widget)
+{
+ EActivityHandler *handler = calendar_component_peek_activity_handler (calendar_component_peek ());
+
+ if(!g_object_get_data ((GObject *) widget, "response-handled")) {
+ g_signal_connect(widget, "response", G_CALLBACK(error_response), NULL);
+ }
+
+ e_activity_handler_make_error (handler, "calendar", E_LOG_WARNINGS, widget);
+}