rem: if (!torbutton_check_socks_remote_dns()) { 
add: if (!torbutton_check_socks_remote_dns()) { 
context: function torbutton_prefs_set_field_attributes(doc){    torbutton_log(4, "called prefs_set_field_attributes()");    var o_torprefs = torbutton_get_prefbranch('extensions.torbutton.');    var o_customprefs = torbutton_get_prefbranch('extensions.torbutton.custom.');    doc.getElementById('torbutton_panelStyle').setAttribute("disabled", !doc.getElementById('torbutton_displayStatusPanel').checked);    doc.getElementById('torbutton_panelStyleText').setAttribute("disabled", !doc.getElementById('torbutton_displayStatusPanel').checked);    doc.getElementById('torbutton_panelStyleIcon').setAttribute("disabled", !doc.getElementById('torbutton_displayStatusPanel').checked);    // Privoxy is always recommended for Firefoxes not support socks_remote_dns    if (!torbutton_check_socks_remote_dns())    {      doc.getElementById('torbutton_usePrivoxy').setAttribute("disabled", true);    } else {	  // XXX: This seems broken.. The first time the prefs window is open it       // is still editable.      doc.getElementById('torbutton_usePrivoxy').setAttribute("disabled", doc.getElementById('torbutton_settingsMethod').value != 'recommended');    }    var proxy_port;    var proxy_host;    if (doc.getElementById('torbutton_usePrivoxy').checked)    {        proxy_host = 'localhost';        proxy_port = 8118;    }    else    {        proxy_host = '';        proxy_port = 0;    }    if (doc.getElementById('torbutton_settingsMethod').value == 'recommended') {        torbutton_log(5, "using recommended settings");        if (!torbutton_check_socks_remote_dns())        {            doc.getElementById('torbutton_httpProxy').value = proxy_host;            doc.getElementById('torbutton_httpPort').value = proxy_port;            doc.getElementById('torbutton_httpsProxy').value = proxy_host;            doc.getElementById('torbutton_httpsPort').value = proxy_port;            doc.getElementById('torbutton_ftpProxy').value = proxy_host;            doc.getElementById('torbutton_ftpPort').value = proxy_port;            doc.getElementById('torbutton_gopherProxy').value = proxy_host;            doc.getElementById('torbutton_gopherPort').value = proxy_port;        } else {            doc.getElementById('torbutton_httpProxy').value = proxy_host;            doc.getElementById('torbutton_httpPort').value = proxy_port;            doc.getElementById('torbutton_httpsProxy').value = proxy_host;            doc.getElementById('torbutton_httpsPort').value = proxy_port;            doc.getElementById('torbutton_ftpProxy').value = '';            doc.getElementById('torbutton_ftpPort').value = 0;            doc.getElementById('torbutton_gopherProxy').value = '';            doc.getElementById('torbutton_gopherPort').value = 0;        }        doc.getElementById('torbutton_socksHost').value = 'localhost';        doc.getElementById('torbutton_socksPort').value = 9050;        doc.getElementById('torbutton_httpProxy').disabled = true;        doc.getElementById('torbutton_httpPort').disabled = true;        doc.getElementById('torbutton_httpsProxy').disabled = true;        doc.getElementById('torbutton_httpsPort').disabled = true;        doc.getElementById('torbutton_ftpProxy').disabled = true;        doc.getElementById('torbutton_ftpPort').disabled = true;        doc.getElementById('torbutton_gopherProxy').disabled = true;        doc.getElementById('torbutton_gopherPort').disabled = true;        doc.getElementById('torbutton_socksHost').disabled = true;        doc.getElementById('torbutton_socksPort').disabled = true;    } else {        doc.getElementById('torbutton_httpProxy').disabled = false;        doc.getElementById('torbutton_httpPort').disabled = false;        doc.getElementById('torbutton_httpsProxy').disabled = false;        doc.getElementById('torbutton_httpsPort').disabled = false;        doc.getElementById('torbutton_ftpProxy').disabled = false;        doc.getElementById('torbutton_ftpPort').disabled = false;        doc.getElementById('torbutton_gopherProxy').disabled = false;        doc.getElementById('torbutton_gopherPort').disabled = false;        doc.getElementById('torbutton_socksHost').disabled = false;        doc.getElementById('torbutton_socksPort').disabled = false;        doc.getElementById('torbutton_httpProxy').value    = o_customprefs.getCharPref('http_proxy');        doc.getElementById('torbutton_httpPort').value     = o_customprefs.getIntPref('http_port');        doc.getElementById('torbutton_httpsProxy').value   = o_customprefs.getCharPref('https_proxy');        doc.getElementById('torbutton_httpsPort').value    = o_customprefs.getIntPref('https_port');        doc.getElementById('torbutton_ftpProxy').value     = o_customprefs.getCharPref('ftp_proxy');        doc.getElementById('torbutton_ftpPort').value      = o_customprefs.getIntPref('ftp_port');        doc.getElementById('torbutton_gopherProxy').value  = o_customprefs.getCharPref('gopher_proxy');        doc.getElementById('torbutton_gopherPort').value   = o_customprefs.getIntPref('gopher_port');        doc.getElementById('torbutton_socksHost').value    = o_customprefs.getCharPref('socks_host');        doc.getElementById('torbutton_socksPort').value    = o_customprefs.getIntPref('socks_port');    }}
meta: 3444	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/3444/6d16d2398792e6b4fdd065aeb02351a0b494ec98/preferences.js/clean/src/chrome/content/preferences.js