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-2016 Eyeo GmbH | 3 * Copyright (C) 2006-2016 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 535 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
546 if (currentElement && msg.remove) | 546 if (currentElement && msg.remove) |
547 { | 547 { |
548 // Hide the selected element itself if an added blocking | 548 // Hide the selected element itself if an added blocking |
549 // filter is causing it to collapse. Note that this | 549 // filter is causing it to collapse. Note that this |
550 // behavior is incomplete, but the best we can do here, | 550 // behavior is incomplete, but the best we can do here, |
551 // e.g. if an added blocking filter matches other elements, | 551 // e.g. if an added blocking filter matches other elements, |
552 // the effect won't be visible until the page is is reloaded. | 552 // the effect won't be visible until the page is is reloaded. |
553 checkCollapse(currentElement.prisoner || currentElement); | 553 checkCollapse(currentElement.prisoner || currentElement); |
554 | 554 |
555 // Apply added element hiding filters. | 555 // Apply added element hiding filters. |
556 updateStylesheet(); | 556 elemhide.apply(); |
557 } | 557 } |
558 deactivateBlockElement(); | 558 deactivateBlockElement(); |
559 break; | 559 break; |
560 case "composer.content.clearPreviousRightClickEvent": | 560 case "composer.content.clearPreviousRightClickEvent": |
561 if (!lastRightClickEventIsMostRecent) | 561 if (!lastRightClickEventIsMostRecent) |
562 lastRightClickEvent = null; | 562 lastRightClickEvent = null; |
563 lastRightClickEventIsMostRecent = false; | 563 lastRightClickEventIsMostRecent = false; |
564 break; | 564 break; |
565 case "composer.content.dialogOpened": | 565 case "composer.content.dialogOpened": |
566 if (window == window.top) | 566 if (window == window.top) |
(...skipping 13 matching lines...) Expand all Loading... |
580 } | 580 } |
581 }); | 581 }); |
582 } | 582 } |
583 break; | 583 break; |
584 } | 584 } |
585 }); | 585 }); |
586 | 586 |
587 if (window == window.top) | 587 if (window == window.top) |
588 ext.backgroundPage.sendMessage({type: "composer.ready"}); | 588 ext.backgroundPage.sendMessage({type: "composer.ready"}); |
589 } | 589 } |
OLD | NEW |