In earlier versions of Firefox I used this line: <script type="application/x-javascript" src="chrome://browser/content/browser.js"/>
It seems that initiating commands from browser.js is no longer possible in Firefox 45. This has caused one of my addons to fail since it makes use of navigation commands such as Browser:ReloadOrDuplicate.
I’m calling the command from an XUL element (a toolbar button) in an XUL overlay. I am not running any of my own Javascript in this extension.
In Firefox 45, the the hamburger menu button becomes non-functional when this line is present. Several toolbar icons also disappear.
I wrote my code over a year ago, when browser.js was still a real file in omni.jar. I am wondering if my code continued to work due to a compatibility layer that has been removed in Firefox 45.
DOM Inspector shows that the commands I am using (such as the one above) remain the same in Firefox 45 as they were in earlier versions. However, it seems they cannot be accessed in the same way.
Have you tried just removing that line? An XUL overlay (on browser.xul?) shouldn’t need it. browser.xul already includes all the scripts it needs, including browser.js. The only scripts you should need to explicitly include are those that are part of your addon. Perhaps it is no longer allowed to include it again.
Also, you don’t actually need browser.js for this. The command element Browser:ReloadOrDuplicate is defined in browser.xul (actually in a file included by browser.xul) and then you don’t need to care where that actually leads (although it currently leads to a function called BrowserReloadOrDuplicate that is in browser.js). Incidentally you could call BrowserReloadOrDuplicate() directly, although making use of a command element is perhaps more reliable.