зеркало из https://github.com/mozilla/gecko-dev.git
106132 - DOM Inspector broken by changes to Pref API, r=jag, sr=hyatt
This commit is contained in:
Родитель
cbe4bebdc2
Коммит
70185e7313
|
@ -13,7 +13,11 @@
|
|||
|
||||
function inspectorNavOnLoad()
|
||||
{
|
||||
var enabled = pref.GetBoolPref("inspector.hooks.navigator");
|
||||
var prefService = Components.classes["@mozilla.org/preferences-service;1"]
|
||||
.getService(Components.interfaces.nsIPrefService);
|
||||
var pref = prefService.getBranch(null);
|
||||
|
||||
var enabled = pref.getBoolPref("inspector.hooks.navigator");
|
||||
if (!enabled) {
|
||||
document.getElementById("context-inspect").setAttribute("hidden", "true");
|
||||
document.getElementById("menu_inspectPage").setAttribute("hidden", "true");
|
||||
|
@ -53,7 +57,7 @@
|
|||
|
||||
<menupopup id="menu_FilePopup">
|
||||
<menuitem id="menu_inspectPage" label="&inspectPageTaskCmd.label;" command="Tasks:InspectPage"
|
||||
accesskey="&inspectPageTaskCmd.accesskey;" key="key_inspectPage"
|
||||
accesskey="&inspectPageTaskCmd.accesskey;" key="key_inspectPage"
|
||||
insertbefore="menu_sendPage"/>
|
||||
</menupopup>
|
||||
|
||||
|
|
|
@ -105,7 +105,7 @@ var PrefUtils =
|
|||
var type = this.mPrefs.getPrefType(aName);
|
||||
try {
|
||||
if (type == nsIPrefBranch.PREF_STRING) {
|
||||
return this.mPrefs.getComplexValue(aName, Components.interfaces.nsISupportsWString);
|
||||
return this.mPrefs.getComplexValue(aName, Components.interfaces.nsISupportsWString).data;
|
||||
} else if (type == nsIPrefBranch.PREF_BOOL) {
|
||||
return this.mPrefs.getBoolPref(aName);
|
||||
} else if (type == nsIPrefBranch.PREF_INT) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче