I’ve seen numerous references to browser.js while trying to create a Firefox sidebar. I don’t have a good understanding of what this file is though. It has a method toggleSidebar in it. Can I call that method from a web page? Can I call it from a browser extension? Do I need to include browser.js in my extension somehow first? Can I call it from the add-on SDK or is it only available from the old style XUL extensions?
I’ve seen numerous references to browser.js while trying to create a Firefox sidebar. I
Share
It is the code driving the Firefox browser window, lots of code actually.
No. You can use window.sidebar.addPanel() to add a sidebar however.
Yes.
No, it is already included in the browser window.
You can use it from the Add-on SDK as well but you will need to access the browser window directly – either via one of the low-level modules or chrome authority.