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

Unified Diff: test/browser/elemHideEmulation.js

Issue 29556808: Issue 5797 - Removed obsolete arguments from ElemHideEmulation constructor (Closed)
Patch Set: Created Sept. 27, 2017, 12:18 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
« lib/content/elemHideEmulation.js ('K') | « lib/content/elemHideEmulation.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/browser/elemHideEmulation.js
===================================================================
--- a/test/browser/elemHideEmulation.js
+++ b/test/browser/elemHideEmulation.js
@@ -109,16 +109,6 @@
return Promise.resolve().then(() =>
{
let elemHideEmulation = new ElemHideEmulation(
- testDocument.defaultView,
- callback =>
- {
- let patterns = [];
- selectors.forEach(selector =>
- {
- patterns.push({selector});
- });
- callback(patterns);
- },
newSelectors =>
{
if (!newSelectors.length)
@@ -133,8 +123,9 @@
}
);
+ elemHideEmulation.document = testDocument;
elemHideEmulation.MIN_INVOCATION_INTERVAL = REFRESH_INTERVAL / 2;
- elemHideEmulation.apply();
+ elemHideEmulation.apply(selectors.map(selector => ({selector})));
return elemHideEmulation;
});
}
« lib/content/elemHideEmulation.js ('K') | « lib/content/elemHideEmulation.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld