Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Issue 5427: Firebug menu added several times with same ids

  • Loading branch information...
commit f2b23d0ec2ac886418032fd66f040bfbfeea0ad9 1 parent cc91b03
@janodvarko janodvarko authored
View
3  extension/content/firebug/chrome/chrome.js
@@ -1056,6 +1056,9 @@ var FirebugChrome =
updateOrient: function(value)
{
var panelPane = FirebugChrome.$("fbPanelPane");
+ if (!panelPane)
+ return;
+
var newOrient = value ? "vertical" : "horizontal";
if (panelPane.orient == newOrient)
return;
View
14 extension/content/firebug/firefox/browserOverlay.js
@@ -361,6 +361,9 @@ Firebug.GlobalUI =
if (popup.state == "open")
return;
+ while (popup.lastChild)
+ popup.removeChild(popup.lastChild);
+
// Generate dynamic content.
for (var i=0; i<firebugMenuContent.length; i++)
popup.appendChild(firebugMenuContent[i].cloneNode(true));
@@ -412,7 +415,7 @@ Firebug.GlobalUI =
closeFirebug.setAttribute("collapsed", (Firebug.currentContext ? "false" : "true"));
}
- // Allow customizing of Firebug menu (see FBTest and FBTrace).
+ // Allow Firebug menu customization (see FBTest and FBTrace as an example).
var event = new CustomEvent("firebugMenuShowing", {detail: popup});
document.dispatchEvent(event);
},
@@ -422,8 +425,13 @@ Firebug.GlobalUI =
if (popup.state == "open")
return;
- while (popup.lastChild)
- popup.removeChild(popup.lastChild);
+ // xxxHonza: I don't know why the timeout must be here, but if it isn't
+ // the icon menu is broken (see issue 5427)
+ setTimeout(function()
+ {
+ while (popup.lastChild)
+ popup.removeChild(popup.lastChild);
+ });
},
onPositionPopupShowing: function(popup)
View
2  extension/content/firebug/lib/options.js
@@ -229,7 +229,7 @@ var Options =
togglePref: function(name)
{
- this.setPref(Options.prefDomain, name, !Firebug[name]);
+ this.set(name, !this.get(name));
},
get: function(name)
Please sign in to comment.
Something went wrong with that request. Please try again.