зеркало из https://github.com/mozilla/pjs.git
Fixes for bug 70348 - autoconfig feature
r = bnesse, sr=alecf and a=dbaron
This commit is contained in:
Родитель
0092a2f373
Коммит
fb2b04ba40
|
@ -61,19 +61,16 @@ function setOfflineUI(offline)
|
|||
|
||||
//Checking for a preference "network.online", if it's locked, disabling
|
||||
// network icon and menu item
|
||||
try {
|
||||
var prefService = Components.classes["@mozilla.org/preferences-service;1"];
|
||||
prefService = prefService.getService();
|
||||
prefService = prefService.QueryInterface(Components.interfaces.nsIPrefService);
|
||||
|
||||
var prefBranch = prefService.getBranch(null);
|
||||
|
||||
var offlineLocked = prefBranch.prefIsLocked("network.online");
|
||||
|
||||
if (offlineLocked ) {
|
||||
broadcaster.setAttribute("disabled","true");
|
||||
}
|
||||
} catch(e) {
|
||||
var prefService = Components.classes["@mozilla.org/preferences-service;1"];
|
||||
prefService = prefService.getService();
|
||||
prefService = prefService.QueryInterface(Components.interfaces.nsIPrefService);
|
||||
|
||||
var prefBranch = prefService.getBranch(null);
|
||||
|
||||
var offlineLocked = prefBranch.prefIsLocked("network.online");
|
||||
|
||||
if (offlineLocked ) {
|
||||
broadcaster.setAttribute("disabled","true");
|
||||
}
|
||||
|
||||
var bundle = srGetStrBundle("chrome://communicator/locale/utilityOverlay.properties");
|
||||
|
|
Загрузка…
Ссылка в новой задаче