[Pkg-mozext-commits] [tabmixplus] 43/47: Update TMP_BrowserOpenTab to set selection and owner (fix changeset bba17b8e9379) backout changeset 4904178f0df6 - Change gBrowser.loadOneTab to include dontMove in its params. loadOneTab don't pass skipAnimation to assTab until Firefox 30
David Prévot
taffit at moszumanska.debian.org
Fri Sep 26 20:57:03 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch upstream
in repository tabmixplus.
commit ba5acfe277df044e4a025c3ed56e4e4bd74d650f
Author: onemen <tabmix.onemen at gmail.com>
Date: Thu Sep 25 14:31:36 2014 +0300
Update TMP_BrowserOpenTab to set selection and owner (fix changeset bba17b8e9379)
backout changeset 4904178f0df6 - Change gBrowser.loadOneTab to include dontMove in its params. loadOneTab don't pass skipAnimation to assTab until Firefox 30
---
chrome/content/links/userInterface.js | 15 ++++++++-------
chrome/content/minit/tablib.js | 18 ++----------------
2 files changed, 10 insertions(+), 23 deletions(-)
diff --git a/chrome/content/links/userInterface.js b/chrome/content/links/userInterface.js
index 2bac778..e0b2f92 100644
--- a/chrome/content/links/userInterface.js
+++ b/chrome/content/links/userInterface.js
@@ -150,12 +150,11 @@ function TMP_BrowserOpenTab(aTab, replaceLastTab) {
var loadInBackground = replaceLastTab ? false :
Tabmix.prefs.getBoolPref("loadNewInBackground");
var loadBlank = isBlankPageURL(url);
- var charset = loadBlank ? null : gBrowser.selectedBrowser.characterSet;
- var newTab = gBrowser.loadOneTab(url, {
- charset: charset,
- inBackground: loadInBackground,
- skipAnimation: replaceLastTab,
- dontMove: true});
+ var newTab = gBrowser.addTab(url, {
+ charset: loadBlank ? null : gBrowser.selectedBrowser.characterSet,
+ ownerTab: loadInBackground ? null : selectedTab,
+ skipAnimation: replaceLastTab,
+ dontMove: true});
if (replaceLastTab) {
newTab.__newLastTab = url;
if (Services.prefs.getCharPref("general.skins.selectedSkin") == "Vista-aero" ) {
@@ -178,8 +177,10 @@ function TMP_BrowserOpenTab(aTab, replaceLastTab) {
// make sure to update recently used tabs
// if user open many tabs quickly select event don't have time to fire
// before new tab select
- if (!loadInBackground)
+ if (!loadInBackground) {
+ gBrowser.selectedTab = newTab;
TMP_LastTab.PushSelectedTab();
+ }
gBrowser.selectedBrowser.focus();
// focus the address bar on new tab
diff --git a/chrome/content/minit/tablib.js b/chrome/content/minit/tablib.js
index f6157ba..49e4ee3 100644
--- a/chrome/content/minit/tablib.js
+++ b/chrome/content/minit/tablib.js
@@ -263,20 +263,6 @@ var tablib = {
'Tabmix.setNumberOfTabsClosedLast();'
).toCode();
}
-
- Tabmix.changeCode(gBrowser, "gBrowser.loadOneTab")._replace(
- 'var aFromExternal;',
- '$&\n' +
- ' var tabmix_dontMove;'
- )._replace(
- 'params = arguments[1];',
- 'params = tablib.definedParams(arguments[1]);\n' +
- ' tabmix_dontMove = params.dontMove;'
- )._replace(
- 'referrerURI: aReferrerURI,',
- '$&\n' +
- ' dontMove: tabmix_dontMove,'
- ).toCode();
},
change_tabContainer: function change_tabContainer() {
@@ -1615,8 +1601,8 @@ var tablib = {
},
// prevent 'ReferenceError: reference to undefined property params'
- // in gBrowser.addTab and gBrowser.loadOneTab
- props: ["referrerURI","charset","postData","inBackground","ownerTab",
+ // in gBrowser.addTab
+ props: ["referrerURI","charset","postData","ownerTab",
"allowThirdPartyFixup","fromExternal","relatedToCurrent",
"allowMixedContent","skipAnimation","isUTF8","dontMove","isPending"],
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/tabmixplus.git
More information about the Pkg-mozext-commits
mailing list