Bug 665678 - Open Add-ons Manager, Data Manager etc. according to Link Behavior preferences (i.e. in a window if the user chose so). f=Ratty r=Neil
--- a/suite/common/utilityOverlay.js
+++ b/suite/common/utilityOverlay.js
@@ -1518,17 +1518,19 @@ function switchToTabHavingURI(aURI, aOpe
if (browserWin.closed || browserWin == window)
continue;
if (switchIfURIInWindow(browserWin))
return true;
}
// No opened tab has that url.
if (aOpenNew) {
- let browserWin = openUILinkIn(aURI.spec, "tabfocused");
+ let newWindowPref = Services.prefs.getIntPref("browser.link.open_external");
+ let where = newWindowPref == kNewTab ? "tabfocused" : "window";
+ let browserWin = openUILinkIn(aURI.spec, where);
if (aCallback) {
browserWin.addEventListener("pageshow", function(event) {
if (event.target.location.href != aURI.spec)
return;
browserWin.removeEventListener("pageshow", arguments.callee, true);
aCallback(browserWin.getBrowser().selectedBrowser);
}, true);
}