From a4d3a57a1cb79209f8e2c7b4e777542d74b5ae12 Mon Sep 17 00:00:00 2001 From: Giovanni Campagna Date: Fri, 18 Feb 2011 16:15:35 +0100 Subject: [PATCH] A11yStatus: fix resetting the GTK and icon themes If the Shell is started with HighContrast enabled, it will never see another value for the GSettings keys. In that case, we just reset to the default. https://bugzilla.gnome.org/show_bug.cgi?id=642641 --- js/ui/status/accessibility.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/ui/status/accessibility.js b/js/ui/status/accessibility.js index b5b6cdbe1..af503706f 100644 --- a/js/ui/status/accessibility.js +++ b/js/ui/status/accessibility.js @@ -168,9 +168,12 @@ ATIndicator.prototype = { if (enabled) { settings.set_string(KEY_GTK_THEME, HIGH_CONTRAST_THEME); settings.set_string(KEY_ICON_THEME, HIGH_CONTRAST_THEME); - } else { + } else if(!hasHC) { settings.set_string(KEY_GTK_THEME, gtkTheme); settings.set_string(KEY_ICON_THEME, iconTheme); + } else { + settings.reset(KEY_GTK_THEME); + settings.reset(KEY_ICON_THEME); } }); settings.connect('changed::' + KEY_GTK_THEME, function() {