Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: chrome/content/elemHideEmulation.js

Issue 29486558: Issue 5404 - :-abp-properties() nested within :-abp-has() should work if the relevant selector refe… (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Created July 11, 2017, 10:20 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/browser/elemHideEmulation.js » ('j') | test/browser/elemHideEmulation.js » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/content/elemHideEmulation.js
===================================================================
--- a/chrome/content/elemHideEmulation.js
+++ b/chrome/content/elemHideEmulation.js
@@ -219,23 +219,19 @@ HasSelector.prototype = {
*/
*getElements(prefix, subtree, styles)
{
let actualPrefix = (!prefix || incompletePrefixRegexp.test(prefix)) ?
prefix + "*" : prefix;
let elements = subtree.querySelectorAll(actualPrefix);
for (let element of elements)
{
- let newPrefix = makeSelector(element, "");
- let iter = evaluate(this._innerSelectors, 0, newPrefix + " ",
- element, styles);
+ let iter = evaluate(this._innerSelectors, 0, "", element, styles);
for (let selector of iter)
- // we insert a space between the two. It becomes a no-op if selector
- // doesn't have a combinator
- if (subtree.querySelector(selector))
+ if (element.querySelector(selector))
yield element;
}
}
};
function PropsSelector(propertyExpression)
{
let regexpString;
« no previous file with comments | « no previous file | test/browser/elemHideEmulation.js » ('j') | test/browser/elemHideEmulation.js » ('J')

Powered by Google App Engine
This is Rietveld