Based on a patch by: Patrick Wade <patrick.wade@sun.com>
2007-09-18 Jens Granseuer <jensgr@gmx.net> Based on a patch by: Patrick Wade <patrick.wade@sun.com> * main.c: (close_logout_update), (setup_dialog): make logout button sensitive whenever accessibility settings have been enabled or disabled (closes bug #476921) svn path=/trunk/; revision=8122
This commit is contained in:
parent
adea3debac
commit
db897ac78e
2 changed files with 14 additions and 2 deletions
|
@ -10,6 +10,8 @@
|
|||
#define ACCESSIBILITY_KEY "/desktop/gnome/interface/accessibility"
|
||||
#define ACCESSIBILITY_KEY_DIR "/desktop/gnome/interface"
|
||||
|
||||
static gboolean initial_state;
|
||||
|
||||
static GladeXML *
|
||||
create_dialog (void)
|
||||
{
|
||||
|
@ -85,9 +87,9 @@ static void
|
|||
close_logout_update (GladeXML *dialog)
|
||||
{
|
||||
GConfClient *client = gconf_client_get_default ();
|
||||
gboolean has_changed = gconf_client_get_bool (client, ACCESSIBILITY_KEY, NULL);
|
||||
gboolean curr_state = gconf_client_get_bool (client, ACCESSIBILITY_KEY, NULL);
|
||||
|
||||
gtk_widget_set_sensitive (WID ("at_close_logout_button"), has_changed);
|
||||
gtk_widget_set_sensitive (WID ("at_close_logout_button"), initial_state != curr_state);
|
||||
g_object_unref (client);
|
||||
}
|
||||
|
||||
|
@ -147,6 +149,8 @@ setup_dialog (GladeXML *dialog)
|
|||
widget,
|
||||
NULL);
|
||||
|
||||
initial_state = gconf_client_get_bool (client, ACCESSIBILITY_KEY, NULL);
|
||||
|
||||
at_enable_update (client, dialog);
|
||||
|
||||
gconf_client_notify_add (client, ACCESSIBILITY_KEY_DIR,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue