зеркало из https://github.com/mozilla/gecko-dev.git
Backed out changeset e388e453977c (bug 1313403) for bc4 bustage a=backout
This commit is contained in:
Родитель
89d1b0e084
Коммит
cdb409b262
|
@ -348,7 +348,6 @@ function openLinkIn(url, where, params) {
|
|||
// result in a new frontmost window (e.g. "javascript:window.open('');").
|
||||
w.focus();
|
||||
|
||||
let browserUsedForLoad = null;
|
||||
switch (where) {
|
||||
case "current":
|
||||
let flags = Ci.nsIWebNavigation.LOAD_FLAGS_NONE;
|
||||
|
@ -384,13 +383,12 @@ function openLinkIn(url, where, params) {
|
|||
postData: aPostData,
|
||||
userContextId: aUserContextId
|
||||
});
|
||||
browserUsedForLoad = aCurrentBrowser;
|
||||
break;
|
||||
case "tabshifted":
|
||||
loadInBackground = !loadInBackground;
|
||||
// fall through
|
||||
case "tab":
|
||||
let tabUsedForLoad = w.gBrowser.loadOneTab(url, {
|
||||
w.gBrowser.loadOneTab(url, {
|
||||
referrerURI: aReferrerURI,
|
||||
referrerPolicy: aReferrerPolicy,
|
||||
charset: aCharset,
|
||||
|
@ -404,15 +402,10 @@ function openLinkIn(url, where, params) {
|
|||
userContextId: aUserContextId,
|
||||
originPrincipal: aPrincipal,
|
||||
});
|
||||
browserUsedForLoad = tabUsedForLoad.linkedBrowser;
|
||||
break;
|
||||
}
|
||||
|
||||
// Focus the content, but only if the browser used for the load is selected.
|
||||
if (browserUsedForLoad &&
|
||||
browserUsedForLoad == browserUsedForLoad.ownerGlobal.gBrowser.selectedBrowser) {
|
||||
browserUsedForLoad.focus();
|
||||
}
|
||||
aCurrentBrowser.focus();
|
||||
|
||||
if (!loadInBackground && w.isBlankPageURL(url)) {
|
||||
w.focusAndSelectUrlBar();
|
||||
|
|
Загрузка…
Ссылка в новой задаче