Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?xml version="1.0"?>
- <bindings id="generalBindings"
- xmlns="http://www.mozilla.org/xbl"
- xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
- xmlns:xbl="http://www.mozilla.org/xbl">
- <binding id="js" extends="chrome://global/content/bindings/toolbarbutton.xml#menu">
- <implementation>
- <constructor><![CDATA[
- function makeRelativePathURI(name) {
- let absolutePath = Components.stack.filename;
- return absolutePath.substring(0, absolutePath.lastIndexOf("/") + 1) + name;
- }
- // The following code executes in the browser context,
- // i.e. chrome://browser/content/browser.xul
- Services.scriptloader.loadSubScript(makeRelativePathURI("userChrome.js"), window);
- ]]></constructor>
- </implementation>
- </binding>
- </bindings>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement