In Firefox dev tools, it seems the XUL iframes won't fire after the initial onload. For example, see the bottom of this file, where the extension makes the selected element in the inspector more easy to see. This is working when you open the inspector, but when you click to another page it reverts to the old inspector tree style. I even tried frame.contentWindow.addEventListener('load',styleit);
, but it doesn't fire when a link is clicked on the web page, and page has loaded.
Asked
Active
Viewed 61 times
0

NoBugs
- 9,310
- 13
- 80
- 146
1 Answers
1
a) get a reference of the InspectorPanel object
b) listen for the ready
event
var ip = window.ownerDocument.defaultView.inspector;`
ip.on("ready", styleit)

paa
- 5,048
- 1
- 18
- 22
-
Close. `window.inspector.on("markuploaded", styleit);` works on page switch. I found that in the `inspector-panel.js`. Do you know if there's any documentation on the .emit and .on that is used in dev tools? – NoBugs Jul 06 '13 at 21:50