1
/* Generated by GOB (v2.0.15) (do not edit directly) */
3
/* End world hunger, donate to the World Food Programme, http://www.wfp.org */
5
#define GOB_VERSION_MAJOR 2
6
#define GOB_VERSION_MINOR 0
7
#define GOB_VERSION_PATCHLEVEL 15
9
#define selfp (self->_priv)
11
#include <string.h> /* memset() */
13
#include "lm-about-dialog.h"
15
#include "lm-about-dialog-private.h"
18
#define ___GOB_LIKELY(expr) G_LIKELY(expr)
19
#define ___GOB_UNLIKELY(expr) G_UNLIKELY(expr)
20
#else /* ! G_LIKELY */
21
#define ___GOB_LIKELY(expr) (expr)
22
#define ___GOB_UNLIKELY(expr) (expr)
25
#line 24 "src/lm-about-dialog.gob"
27
#include <glib/gi18n.h>
31
#line 32 "lm-about-dialog.c"
32
/* self casting macros */
33
#define SELF(x) LM_ABOUT_DIALOG(x)
34
#define SELF_CONST(x) LM_ABOUT_DIALOG_CONST(x)
35
#define IS_SELF(x) LM_IS_ABOUT_DIALOG(x)
36
#define TYPE_SELF LM_TYPE_ABOUT_DIALOG
37
#define SELF_CLASS(x) LM_ABOUT_DIALOG_CLASS(x)
39
#define SELF_GET_CLASS(x) LM_ABOUT_DIALOG_GET_CLASS(x)
42
typedef LMAboutDialog Self;
43
typedef LMAboutDialogClass SelfClass;
45
/* here are local prototypes */
46
#line 32 "src/lm-about-dialog.gob"
47
static void lm_about_dialog_class_init (LMAboutDialogClass * class);
48
#line 49 "lm-about-dialog.c"
49
#line 38 "src/lm-about-dialog.gob"
50
static void lm_about_dialog_init (LMAboutDialog * self);
51
#line 52 "lm-about-dialog.c"
52
#line 66 "src/lm-about-dialog.gob"
53
static void lm_about_dialog_activate_link_cb (GtkAboutDialog * about, const char * link_, gpointer data);
54
#line 55 "lm-about-dialog.c"
56
/* pointer to the class of our parent */
57
static GtkAboutDialogClass *parent_class = NULL;
59
/* Short form macros */
60
#define self_activate_link_cb lm_about_dialog_activate_link_cb
62
lm_about_dialog_get_type (void)
64
static GType type = 0;
66
if ___GOB_UNLIKELY(type == 0) {
67
static const GTypeInfo info = {
68
sizeof (LMAboutDialogClass),
70
(GBaseFinalizeFunc) NULL,
71
(GClassInitFunc) lm_about_dialog_class_init,
72
(GClassFinalizeFunc) NULL,
73
NULL /* class_data */,
74
sizeof (LMAboutDialog),
76
(GInstanceInitFunc) lm_about_dialog_init,
80
type = g_type_register_static (GTK_TYPE_ABOUT_DIALOG, "LMAboutDialog", &info, (GTypeFlags)0);
86
/* a macro for creating a new object of our type */
87
#define GET_NEW ((LMAboutDialog *)g_object_new(lm_about_dialog_get_type(), NULL))
89
/* a function for creating a new object of our type */
91
static LMAboutDialog * GET_NEW_VARG (const char *first, ...) G_GNUC_UNUSED;
92
static LMAboutDialog *
93
GET_NEW_VARG (const char *first, ...)
98
ret = (LMAboutDialog *)g_object_new_valist (lm_about_dialog_get_type (), first, ap);
103
#line 32 "src/lm-about-dialog.gob"
105
lm_about_dialog_class_init (LMAboutDialogClass * class G_GNUC_UNUSED)
107
#line 108 "lm-about-dialog.c"
108
#define __GOB_FUNCTION__ "LM:About:Dialog::class_init"
110
parent_class = g_type_class_ref (GTK_TYPE_ABOUT_DIALOG);
113
#line 33 "src/lm-about-dialog.gob"
115
gtk_about_dialog_set_email_hook(self_activate_link_cb, "mailto:", NULL);
116
gtk_about_dialog_set_url_hook(self_activate_link_cb, NULL, NULL);
118
#line 119 "lm-about-dialog.c"
121
#undef __GOB_FUNCTION__
122
#line 38 "src/lm-about-dialog.gob"
124
lm_about_dialog_init (LMAboutDialog * self G_GNUC_UNUSED)
126
#line 127 "lm-about-dialog.c"
127
#define __GOB_FUNCTION__ "LM:About:Dialog::init"
129
#line 39 "src/lm-about-dialog.gob"
131
GtkAboutDialog *about = GTK_ABOUT_DIALOG(self);
132
const char *authors[] = { "Jean-Yves Lefort <jylefort@brutele.be>", NULL };
133
const char *documenters[] = { "Jean-Yves Lefort <jylefort@brutele.be>", NULL };
136
/* translators: header capitalization */
137
gtk_about_dialog_set_program_name(about, _("Link Monitor"));
138
gtk_about_dialog_set_version(about, VERSION);
139
gtk_about_dialog_set_copyright(about, "Copyright \302\251 2004-2008 Jean-Yves Lefort");
140
gtk_about_dialog_set_comments(about, _("The link monitor displays the round-trip time to one or more hosts."));
141
gtk_about_dialog_set_website(about, "http://www.nongnu.org/link-monitor");
142
gtk_about_dialog_set_authors(about, authors);
143
gtk_about_dialog_set_documenters(about, documenters);
145
* translators: Your Name <your-email>
146
* optionally followed by one or more: \nOther Contributor's Name <his-email>
148
gtk_about_dialog_set_translator_credits(about, _("translator-credits"));
150
logo = lm_pixbuf_new(GNOMEPIXMAPSDIR G_DIR_SEPARATOR_S "link-monitor-applet.png");
151
gtk_about_dialog_set_logo(about, logo);
152
g_object_unref(logo);
154
g_signal_connect(self, "response", G_CALLBACK(gtk_widget_destroy), NULL);
156
#line 157 "lm-about-dialog.c"
159
#undef __GOB_FUNCTION__
163
#line 66 "src/lm-about-dialog.gob"
165
lm_about_dialog_activate_link_cb (GtkAboutDialog * about, const char * link_, gpointer data)
167
#line 168 "lm-about-dialog.c"
168
#define __GOB_FUNCTION__ "LM:About:Dialog::activate_link_cb"
170
#line 70 "src/lm-about-dialog.gob"
173
const char *prefix = data;
176
url = prefix ? g_strconcat(prefix, link_, NULL) : g_strdup(link_);
177
if (! gnome_url_show(url, &err))
179
lm_show_error_dialog(GTK_WINDOW(about), _("Unable to open link"), "%s", err->message);
184
#line 185 "lm-about-dialog.c"
185
#undef __GOB_FUNCTION__