From d3b09614221d075452496a5198a3910d07eb2818 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Wed, 29 Sep 2010 10:47:32 -0400 Subject: EAlert cleanups. Clean up the header, drop some unused cruft. --- e-util/e-alert.c | 42 ++++++++++-------------------------------- 1 file changed, 10 insertions(+), 32 deletions(-) (limited to 'e-util/e-alert.c') diff --git a/e-util/e-alert.c b/e-util/e-alert.c index e4e698fae7..49ba6af36b 100644 --- a/e-util/e-alert.c +++ b/e-util/e-alert.c @@ -41,6 +41,10 @@ #define d(x) +#define E_ALERT_GET_PRIVATE(obj) \ + (G_TYPE_INSTANCE_GET_PRIVATE \ + ((obj), E_TYPE_ALERT, EAlertPrivate)) + struct _e_alert { guint32 flags; const gchar *id; @@ -49,7 +53,6 @@ struct _e_alert { const gchar *title; const gchar *primary; const gchar *secondary; - const gchar *help_uri; gboolean scroll; struct _e_alert_button *buttons; }; @@ -70,17 +73,11 @@ static struct _e_alert_button default_ok_button = { static struct _e_alert default_alerts[] = { { GTK_DIALOG_MODAL, "error", 3, GTK_RESPONSE_OK, - N_("Evolution Error"), "{0}", "{1}", NULL, FALSE, - &default_ok_button }, - { GTK_DIALOG_MODAL, "error-primary", 3, GTK_RESPONSE_OK, - N_("Evolution Error"), "{0}", NULL, NULL, FALSE, + N_("Evolution Error"), "{0}", "{1}", FALSE, &default_ok_button }, { GTK_DIALOG_MODAL, "warning", 1, GTK_RESPONSE_OK, - N_("Evolution Warning"), "{0}", "{1}", NULL, FALSE, - &default_ok_button }, - { GTK_DIALOG_MODAL, "warning-primary", 1, GTK_RESPONSE_OK, - N_("Evolution Warning"), "{0}", NULL, NULL, FALSE, - &default_ok_button }, + N_("Evolution Warning"), "{0}", "{1}", FALSE, + &default_ok_button } }; /* ********************************************************************** */ @@ -141,18 +138,13 @@ G_DEFINE_TYPE ( e_alert, G_TYPE_OBJECT) -#define ALERT_PRIVATE(o) \ - (G_TYPE_INSTANCE_GET_PRIVATE ((o), E_TYPE_ALERT, EAlertPrivate)) - -enum -{ +enum { PROP_0, PROP_TAG, PROP_ARGS }; -struct _EAlertPrivate -{ +struct _EAlertPrivate { gchar *tag; GPtrArray *args; struct _e_alert *definition; @@ -166,7 +158,6 @@ struct _EAlertPrivate Window Title? Primary error text.? Secondary error text.? - ?