Left: | ||
Right: |
OLD | NEW |
---|---|
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-2015 Eyeo GmbH | 3 * Copyright (C) 2006-2015 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 537 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
548 case "add-sitekey": | 548 case "add-sitekey": |
549 processKey(msg.token, sender.page, sender.frame); | 549 processKey(msg.token, sender.page, sender.frame); |
550 break; | 550 break; |
551 case "report-html-page": | 551 case "report-html-page": |
552 htmlPages.set(sender.page, null); | 552 htmlPages.set(sender.page, null); |
553 refreshIconAndContextMenu(sender.page); | 553 refreshIconAndContextMenu(sender.page); |
554 break; | 554 break; |
555 case "compose-filters": | 555 case "compose-filters": |
556 sendResponse(composeFilters( | 556 sendResponse(composeFilters( |
557 msg.tagName, msg.id, msg.src, msg.style, | 557 msg.tagName, msg.id, msg.src, msg.style, |
558 msg.classes, msg.urls, new URL(msg.baseURL) | 558 msg.classes, msg.urls, msg.mediatype, |
559 msg.baseURL, sender.page, sender.frame | |
Wladimir Palant
2015/03/02 20:14:19
Ten positional parameters in a function is certain
Sebastian Noack
2015/03/03 14:29:00
How about reducing the number of arguments by grou
Wladimir Palant
2015/03/03 14:40:31
That's eight parameters now - still way too many t
Sebastian Noack
2015/03/03 14:59:28
Fair enough.
| |
559 )); | 560 )); |
560 break; | 561 break; |
561 case "forward": | 562 case "forward": |
562 if (sender.page) | 563 if (sender.page) |
563 { | 564 { |
564 if (msg.expectsResponse) | 565 if (msg.expectsResponse) |
565 { | 566 { |
566 sender.page.sendMessage(msg.payload, sendResponse); | 567 sender.page.sendMessage(msg.payload, sendResponse); |
567 return true; | 568 return true; |
568 } | 569 } |
(...skipping 10 matching lines...) Expand all Loading... | |
579 page.sendMessage({type: "clickhide-deactivate"}); | 580 page.sendMessage({type: "clickhide-deactivate"}); |
580 refreshIconAndContextMenu(page); | 581 refreshIconAndContextMenu(page); |
581 }); | 582 }); |
582 | 583 |
583 setTimeout(function() | 584 setTimeout(function() |
584 { | 585 { |
585 var notificationToShow = NotificationStorage.getNextToShow(); | 586 var notificationToShow = NotificationStorage.getNextToShow(); |
586 if (notificationToShow) | 587 if (notificationToShow) |
587 showNotification(notificationToShow); | 588 showNotification(notificationToShow); |
588 }, 3 * 60 * 1000); | 589 }, 3 * 60 * 1000); |
OLD | NEW |