Utilizar a API do Inspetor
Firefox add-ons may access the following objects from the chrome://browser/content/devtools/inspector/inspector.xul context:
defined in inspector-panel.js. Attributes and functions:
- .selection - information about the inspector's selection:
- .isNode() - returns true if selection is node.
- .node - returns the actual element from the page
- .window - the window object of the frame the selection is in.
- .markDirty() - marks that the page has been changed by the inspector - a warning will be shown when leaving the page, since changes made through the inspector are rewritten on reload.
Bindable events using on:
Called when the left panel has been refreshed, after page change.
Called on first markuploaded.
Called after toggle of a pseudoclass.
"low-priority change event for things like paint and resize."