mirror of
https://github.com/gorhill/uBlock.git
synced 2024-09-15 07:22:28 +02:00
this addresses https://www.reddit.com/r/pathofexile/comments/3okptl/ublock_origins_wont_let_me_open_links_in_new_tabs/cvyd5xb
This commit is contained in:
parent
a3ed66688b
commit
6cb185c973
@ -919,11 +919,15 @@ var uBlockCollapser = (function() {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
var onMouseClick = function(ev) {
|
var onMouseClick = function(ev) {
|
||||||
|
var elem = ev.target;
|
||||||
|
while ( elem !== null && elem.localName !== 'a' ) {
|
||||||
|
elem = elem.parentElement;
|
||||||
|
}
|
||||||
messager.send({
|
messager.send({
|
||||||
what: 'mouseClick',
|
what: 'mouseClick',
|
||||||
x: ev.clientX,
|
x: ev.clientX,
|
||||||
y: ev.clientY,
|
y: ev.clientY,
|
||||||
url: ev.target && ev.target.localName === 'a' ? ev.target.href : ''
|
url: elem !== null ? elem.href : ''
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user