a11y-status: Fix left over GConf usage

Commit f0c6e96e82 updated the "Large Text" action to use a GSettings
key, but left some code accessing the setting via GConf.

https://bugzilla.gnome.org/show_bug.cgi?id=634693
This commit is contained in:
Florian Müllner 2010-11-12 19:37:51 +01:00
parent f0c6e96e82
commit b2495a0e25

View File

@ -82,7 +82,7 @@ ATIndicator.prototype = {
let magnifier = this._buildMagItem(); let magnifier = this._buildMagItem();
this.menu.addMenuItem(magnifier); this.menu.addMenuItem(magnifier);
let textZoom = this._buildFontItem(client); let textZoom = this._buildFontItem();
this.menu.addMenuItem(textZoom); this.menu.addMenuItem(textZoom);
let screenReader = this._buildItem(_("Screen Reader"), AT_SCREEN_READER_SCHEMA, 'startup'); let screenReader = this._buildItem(_("Screen Reader"), AT_SCREEN_READER_SCHEMA, 'startup');
@ -189,7 +189,7 @@ ATIndicator.prototype = {
return highContrast; return highContrast;
}, },
_buildFontItem: function(client) { _buildFontItem: function() {
let settings = new Gio.Settings({ schema: XSETTINGS_SCHEMA }); let settings = new Gio.Settings({ schema: XSETTINGS_SCHEMA });
// we assume this never changes (which is not true if resolution // we assume this never changes (which is not true if resolution
@ -207,9 +207,9 @@ ATIndicator.prototype = {
settings.is_writable(KEY_DPI), settings.is_writable(KEY_DPI),
function (enabled) { function (enabled) {
if (enabled) if (enabled)
client.set_float(KEY_DPI, DPI_FACTOR_LARGE * default_value); settings.set_double(KEY_DPI, DPI_FACTOR_LARGE * default_value);
else else
client.set_float(KEY_DPI, default_value); settings.set_double(KEY_DPI, default_value);
}); });
settings.connect('changed::' + KEY_DPI, function() { settings.connect('changed::' + KEY_DPI, function() {
let active = on_get(); let active = on_get();