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

Side by Side Diff: lib/filterClasses.js

Issue 5825855188107264: Issue 419 - ElemHideFilter.domains getter doesn`t persist on Safari (Closed)
Patch Set: Created May 5, 2014, 10:24 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 | no next file » | no next file with comments »
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 <http://adblockplus.org/>, 2 * This file is part of Adblock Plus <http://adblockplus.org/>,
3 * Copyright (C) 2006-2014 Eyeo GmbH 3 * Copyright (C) 2006-2014 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 349 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 domains = {__proto__: null}; 360 domains = {__proto__: null};
361 361
362 domains[domain] = include; 362 domains[domain] = include;
363 } 363 }
364 domains[""] = !hasIncludes; 364 domains[""] = !hasIncludes;
365 } 365 }
366 366
367 this.domainSource = null; 367 this.domainSource = null;
368 } 368 }
369 369
370 this.__defineGetter__("domains", function() domains); 370 Object.defineProperty(this, "domains", {value: domains, enumerable: true});
371 return this.domains; 371 return this.domains;
372 }, 372 },
373 373
374 /** 374 /**
375 * Checks whether this filter is active on a domain. 375 * Checks whether this filter is active on a domain.
376 */ 376 */
377 isActiveOnDomain: function(/**String*/ docDomain) /**Boolean*/ 377 isActiveOnDomain: function(/**String*/ docDomain) /**Boolean*/
378 { 378 {
379 // If no domains are set the rule matches everywhere 379 // If no domains are set the rule matches everywhere
380 if (!this.domains) 380 if (!this.domains)
(...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after
882 function ElemHideException(text, domains, selector) 882 function ElemHideException(text, domains, selector)
883 { 883 {
884 ElemHideBase.call(this, text, domains, selector); 884 ElemHideBase.call(this, text, domains, selector);
885 } 885 }
886 exports.ElemHideException = ElemHideException; 886 exports.ElemHideException = ElemHideException;
887 887
888 ElemHideException.prototype = 888 ElemHideException.prototype =
889 { 889 {
890 __proto__: ElemHideBase.prototype 890 __proto__: ElemHideBase.prototype
891 }; 891 };
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld