461 self.__adBlockDialog = AdBlockDialog(self) |
461 self.__adBlockDialog = AdBlockDialog(self) |
462 |
462 |
463 self.__adBlockDialog.show() |
463 self.__adBlockDialog.show() |
464 return self.__adBlockDialog |
464 return self.__adBlockDialog |
465 |
465 |
466 def elementHidingRules(self): |
466 def elementHidingRules(self, url): |
467 """ |
467 """ |
468 Public method to get the element hiding rules. |
468 Public method to get the element hiding rules. |
469 |
469 |
|
470 |
|
471 @param url URL to get hiding rules for (QUrl) |
470 @return element hiding rules (string) |
472 @return element hiding rules (string) |
471 """ |
473 """ |
472 if not self.isEnabled(): |
474 if not self.isEnabled() or not self.__canRunOnScheme(url.scheme()): |
473 return "" |
475 return "" |
474 |
476 |
475 rules = "" |
477 rules = "" |
476 |
478 |
477 for subscription in self.__subscriptions: |
479 for subscription in self.__subscriptions: |