[Pkg-mozext-commits] [tabmixplus] 96/123: With Firefox 17.0-20.0 modules/ContentClick.jsm can't pass aEvent.__where to handleLinkClick
David Prévot
taffit at moszumanska.debian.org
Wed Sep 17 21:16:30 UTC 2014
This is an automated email from the git hooks/post-receive script.
taffit pushed a commit to branch master
in repository tabmixplus.
commit 23dd7b9148b27f6b38f1f7ffdab65a4c19112c3d
Author: onemen <tabmix.onemen at gmail.com>
Date: Fri Sep 12 01:07:57 2014 +0300
With Firefox 17.0-20.0 modules/ContentClick.jsm can't pass aEvent.__where to handleLinkClick
---
chrome/content/links/contentLinks.js | 4 ++++
modules/ContentClick.jsm | 4 +++-
2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/chrome/content/links/contentLinks.js b/chrome/content/links/contentLinks.js
index c22fc00..e7cfa0a 100644
--- a/chrome/content/links/contentLinks.js
+++ b/chrome/content/links/contentLinks.js
@@ -48,6 +48,10 @@ Tabmix.contentAreaClick = {
* Tabmix.contentAreaClick.contentLinkClick
*/
Tabmix.changeCode(window, "handleLinkClick")._replace(
+ '{', '{\n'+
+ ' if (arguments.length > 3)\n'+
+ ' event.__where = arguments[3] && arguments[3].where;'
+ )._replace(
'whereToOpenLink(event);',
'$&\n' +
' if (event && event.__where && event.__where != "default" &&\n' +
diff --git a/modules/ContentClick.jsm b/modules/ContentClick.jsm
index 2c31925..f6c0b42 100644
--- a/modules/ContentClick.jsm
+++ b/modules/ContentClick.jsm
@@ -508,7 +508,9 @@ let ContentClickInternal = {
let where = this._window.whereToOpenLink(aEvent);
aEvent.__where = where == "tabshifted" ? "tabshifted" : "tab";
- this._window.handleLinkClick(aEvent, aEvent.__hrefFromOnClick || href, linkNode);
+ // in Firefox 17.0-20.0 we can't pass aEvent.__where to handleLinkClick
+ // add 4th argumens with where value
+ this._window.handleLinkClick(aEvent, aEvent.__hrefFromOnClick || href, linkNode, {where: aEvent.__where});
aEvent.stopPropagation();
aEvent.preventDefault();
return "17";
--
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