From 5000af2e58c67722f1db9a3c6736b425f5fb376c Mon Sep 17 00:00:00 2001 From: Jody Goldberg Date: Thu, 9 May 2002 18:25:46 +0000 Subject: [PATCH] add a help button. ditto. 2002-05-09 Jody Goldberg * gnome-ui-properties.glade : add a help button. * gnome-ui-properties.c (dialog_button_clicked_cb) : ditto. --- capplets/ui-properties/ChangeLog | 5 +++++ capplets/ui-properties/gnome-ui-properties.c | 22 ++++++++++++------- .../ui-properties/gnome-ui-properties.glade | 13 ++++++++++- 3 files changed, 31 insertions(+), 9 deletions(-) diff --git a/capplets/ui-properties/ChangeLog b/capplets/ui-properties/ChangeLog index 8a3912ef0..5af12b3f7 100644 --- a/capplets/ui-properties/ChangeLog +++ b/capplets/ui-properties/ChangeLog @@ -1,3 +1,8 @@ +2002-05-09 Jody Goldberg + + * gnome-ui-properties.glade : add a help button. + * gnome-ui-properties.c (dialog_button_clicked_cb) : ditto. + 2002-05-06 jacob berkman * ui-properties.glade.h: remove unused file diff --git a/capplets/ui-properties/gnome-ui-properties.c b/capplets/ui-properties/gnome-ui-properties.c index cce269503..d7533cba9 100644 --- a/capplets/ui-properties/gnome-ui-properties.c +++ b/capplets/ui-properties/gnome-ui-properties.c @@ -77,14 +77,20 @@ toolbar_to_widget (GConfPropertyEditor *peditor, GConfValue *value) static void dialog_button_clicked_cb (GtkDialog *dialog, gint response_id, GConfChangeSet *changeset) { - switch (response_id) - { - case RESPONSE_CLOSE: - case GTK_RESPONSE_DELETE_EVENT: - default: - gtk_main_quit (); - break; - } + if (response_id == GTK_RESPONSE_HELP) { + GError *error = NULL; + + /* TODO : get this written */ + gnome_help_display_desktop (NULL, + "control-center-manual", + "config-ui-properties.xml", + "CONFIGURATION", &error); + if (error) { + g_warning ("help error: %s\n", error->message); + g_error_free (error); + } + } else + gtk_main_quit (); } static GladeXML * diff --git a/capplets/ui-properties/gnome-ui-properties.glade b/capplets/ui-properties/gnome-ui-properties.glade index 6b6b95151..7d31df916 100644 --- a/capplets/ui-properties/gnome-ui-properties.glade +++ b/capplets/ui-properties/gnome-ui-properties.glade @@ -27,7 +27,18 @@ 10 - + + True + True + True + gtk-help + True + GTK_RELIEF_NORMAL + -11 + + + + True True True