From 5e58353ddd1a83e11ebbbf13f64d7d0cfd56c072 Mon Sep 17 00:00:00 2001 From: Not Zed Date: Mon, 16 May 2005 06:09:50 +0000 Subject: move e-error.[ch] and e-system-errors.xml to e-util/. remove test-error. 2005-05-16 Not Zed * Makefile.am: move e-error.[ch] and e-system-errors.xml to e-util/. remove test-error. svn path=/trunk/; revision=29359 --- widgets/misc/ChangeLog | 5 + widgets/misc/Makefile.am | 22 +- widgets/misc/e-error.c | 628 ------------------------------------- widgets/misc/e-error.h | 57 ---- widgets/misc/e-system-errors.xml | 22 -- widgets/misc/e-system-errors.xml.h | 15 - 6 files changed, 6 insertions(+), 743 deletions(-) delete mode 100644 widgets/misc/e-error.c delete mode 100644 widgets/misc/e-error.h delete mode 100644 widgets/misc/e-system-errors.xml delete mode 100644 widgets/misc/e-system-errors.xml.h (limited to 'widgets') diff --git a/widgets/misc/ChangeLog b/widgets/misc/ChangeLog index 5e714f5bc5..d91a94722a 100644 --- a/widgets/misc/ChangeLog +++ b/widgets/misc/ChangeLog @@ -1,3 +1,8 @@ +2005-05-16 Not Zed + + * Makefile.am: move e-error.[ch] and e-system-errors.xml to + e-util/. remove test-error. + 2005-05-13 Rodney Dawes * e-filter-bar.[ch]: Update for the new menu layout diff --git a/widgets/misc/Makefile.am b/widgets/misc/Makefile.am index c63eb565fb..03ab98864f 100644 --- a/widgets/misc/Makefile.am +++ b/widgets/misc/Makefile.am @@ -38,7 +38,6 @@ widgetsinclude_HEADERS = \ e-combo-button.h \ e-dateedit.h \ e-dropdown-button.h \ - e-error.h \ e-expander.h \ e-image-chooser.h \ e-info-label.h \ @@ -67,7 +66,6 @@ libemiscwidgets_la_SOURCES = \ e-combo-button.c \ e-dateedit.c \ e-dropdown-button.c \ - e-error.c \ e-expander.c \ e-image-chooser.c \ e-info-label.c \ @@ -82,12 +80,6 @@ libemiscwidgets_la_SOURCES = \ MARSHAL_GENERATED = e-util-marshal.c e-util-marshal.h @EVO_MARSHAL_RULE@ -error_DATA = e-system-errors.xml -error_i18n = $(error_DATA:.xml=.xml.h) -errordir = $(privdatadir)/errors -%.xml.h: %.xml - $(top_builddir)/e-util/e-error-tool $^ - libemiscwidgets_la_LIBADD = $(top_builddir)/e-util/libeutil.la \ $(top_builddir)/a11y/widgets/libevolution-widgets-a11y.la \ $(E_WIDGETS_LIBS) @@ -100,7 +92,6 @@ noinst_PROGRAMS = \ test-calendar \ test-dateedit \ test-dropdown-button \ - test-error \ test-multi-config-dialog \ test-info-label @@ -154,22 +145,11 @@ test_info_label_LDADD = \ $(top_builddir)/e-util/libeutil.la \ $(E_WIDGETS_LIBS) -test_error_SOURCES = \ - test-error.c - -test_error_LDADD = \ - $(top_builddir)/e-util/libeutil.la \ - ./libemiscwidgets.la \ - $(E_WIDGETS_LIBS) - - -BUILT_SOURCES = $(MARSHAL_GENERATED) $(error_i18n) +BUILT_SOURCES = $(MARSHAL_GENERATED) CLEANFILES = $(BUILT_SOURCES) EXTRA_DIST = \ $(glade_DATA) \ - $(error_DATA) \ - $(error_i18n) \ e-pilot-settings.h \ e-pilot-settings.c \ e-util-marshal.list \ diff --git a/widgets/misc/e-error.c b/widgets/misc/e-error.c deleted file mode 100644 index f7dc888609..0000000000 --- a/widgets/misc/e-error.c +++ /dev/null @@ -1,628 +0,0 @@ -/* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- * - * - * Authors: Michael Zucchi - * - * Copyright 2004 Novell Inc. (www.novell.com) - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of version 2 of the GNU General Public - * License as published by the Free Software Foundation. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Street #330, Boston, MA 02111-1307, USA. - * - */ - -#ifdef HAVE_CONFIG_H -#include -#endif - -#include -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include - -#include "e-error.h" - -#define d(x) - -struct _e_error_button { - struct _e_error_button *next; - char *stock; - char *label; - int response; -}; - -struct _e_error { - guint32 flags; - char *id; - int type; - int default_response; - char *title; - char *primary; - char *secondary; - char *help_uri; - struct _e_error_button *buttons; -}; - -struct _e_error_table { - char *domain; - char *translation_domain; - GHashTable *errors; -}; - -static GHashTable *error_table; -static GSList *ee_parent_list; - -/* ********************************************************************** */ - -static struct _e_error_button default_ok_button = { - NULL, "gtk-ok", NULL, GTK_RESPONSE_OK -}; - -static struct _e_error default_errors[] = { - { GTK_DIALOG_MODAL, "error", 3, GTK_RESPONSE_OK, N_("Evolution Error"), "{0}", "{1}", NULL, &default_ok_button }, - { GTK_DIALOG_MODAL, "error-primary", 3, GTK_RESPONSE_OK, N_("Evolution Error"), "{0}", NULL, NULL, &default_ok_button }, - { GTK_DIALOG_MODAL, "warning", 1, GTK_RESPONSE_OK, N_("Evolution Warning"), "{0}", "{1}", NULL, &default_ok_button }, - { GTK_DIALOG_MODAL, "warning-primary", 1, GTK_RESPONSE_OK, N_("Evolution Warning"), "{0}", NULL, NULL, &default_ok_button }, -}; - -/* ********************************************************************** */ - -static struct { - char *name; - int id; -} response_map[] = { - { "GTK_RESPONSE_REJECT", GTK_RESPONSE_REJECT }, - { "GTK_RESPONSE_ACCEPT", GTK_RESPONSE_ACCEPT }, - { "GTK_RESPONSE_OK", GTK_RESPONSE_OK }, - { "GTK_RESPONSE_CANCEL", GTK_RESPONSE_CANCEL }, - { "GTK_RESPONSE_CLOSE", GTK_RESPONSE_CLOSE }, - { "GTK_RESPONSE_YES", GTK_RESPONSE_YES }, - { "GTK_RESPONSE_NO", GTK_RESPONSE_NO }, - { "GTK_RESPONSE_APPLY", GTK_RESPONSE_APPLY }, - { "GTK_RESPONSE_HELP", GTK_RESPONSE_HELP }, -}; - -static int -map_response(const char *name) -{ - int i; - - for (i=0;i - Window Title? - Primary error text.? - Secondary error text.? - ? -