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

Side by Side Diff: lib/content/elemHideEmulation.js

Issue 29770601: Issue 6649 - Allow u flag in :-abp-contains() (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Add tests Created May 5, 2018, 2 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | test/browser/elemHideEmulation.js » ('j') | test/browser/elemHideEmulation.js » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * This file is part of Adblock Plus <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-present eyeo GmbH 3 * Copyright (C) 2006-present eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 } 169 }
170 return all ? subtree.querySelectorAll(selector) : 170 return all ? subtree.querySelectorAll(selector) :
171 subtree.querySelector(selector); 171 subtree.querySelector(selector);
172 } 172 }
173 173
174 function scopedQuerySelectorAll(subtree, selector) 174 function scopedQuerySelectorAll(subtree, selector)
175 { 175 {
176 return scopedQuerySelector(subtree, selector, true); 176 return scopedQuerySelector(subtree, selector, true);
177 } 177 }
178 178
179 const regexpRegexp = /^\/(.*)\/([im]*)$/; 179 const regexpRegexp = /^\/(.*)\/([imu]*)$/;
180 180
181 /** 181 /**
182 * Make a regular expression from a text argument. If it can be parsed as a 182 * Make a regular expression from a text argument. If it can be parsed as a
183 * regular expression, parse it and the flags. 183 * regular expression, parse it and the flags.
184 * @param {string} text the text argument. 184 * @param {string} text the text argument.
185 * @return {?RegExp} a RegExp object or null in case of error. 185 * @return {?RegExp} a RegExp object or null in case of error.
186 */ 186 */
187 function makeRegExpParameter(text) 187 function makeRegExpParameter(text)
188 { 188 {
189 let [, pattern, flags] = 189 let [, pattern, flags] =
(...skipping 675 matching lines...) Expand 10 before | Expand all | Expand 10 after
865 characterData: shouldObserveCharacterData(this.patterns), 865 characterData: shouldObserveCharacterData(this.patterns),
866 subtree: true 866 subtree: true
867 } 867 }
868 ); 868 );
869 this.document.addEventListener("load", this.onLoad.bind(this), true); 869 this.document.addEventListener("load", this.onLoad.bind(this), true);
870 } 870 }
871 } 871 }
872 }; 872 };
873 873
874 exports.ElemHideEmulation = ElemHideEmulation; 874 exports.ElemHideEmulation = ElemHideEmulation;
OLDNEW
« 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