Opened on 09/08/2017 at 06:53:03 PM

Closed on 09/15/2017 at 11:52:10 AM

Last modified on 09/15/2017 at 06:50:55 PM

#5648 closed change (fixed)

Add lib/popupBlocker.js to Firefox version with a dynamic check for webNavigation.onCreatedNavigationTarget support

Reported by: mjethani Assignee: mjethani
Priority: P2 Milestone: Adblock-Plus-3.0-for-Firefox
Module: Platform Keywords:
Cc: sebastian, trev Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Unknown Verified working: no
Review URL(s):



Firefox added support for webNavigation.onCreatedNavigationTarget in version 54, but the WebExtensions version of ABP for Firefox still doesn't support popup blocking even in newer versions of the browser.

What to change

Edit metadata.gecko-webext to include lib/popupBlocker.js in lib/adblockplus.js

In lib/popupBlocker.js check for the existence of webNavigation.onCreatedNavigationTarget before trying to add the event listener.

Hints for testers

Simply add the filter $popup to test this.

On Firefox 54 for desktop, any time a page is opened in a new tab/window, either by user action (e.g. by clicking on "Open Link in New Tab" in the context menu) or programmatically (e.g. the page's JavaScript code calling with a URL), the action should get blocked with this filter (i.e. the tab/window should get prevented from opening). On Firefox 55 onwards you should be able to see this in the browser's devtools panel. Note that popups that are already blocked by the browser's own built-in popup blocker won't be blocked by Adblock Plus.

On Firefox 54 for Android, only tabs opened with will get blocked.

Attachments (0)

Change History (5)

comment:1 Changed on 09/08/2017 at 06:54:26 PM by mjethani

  • Cc sebastian trev added

comment:2 Changed on 09/08/2017 at 08:33:18 PM by sebastian

  • Priority changed from Unknown to P2
  • Ready set

comment:3 Changed on 09/15/2017 at 11:50:45 AM by abpbot

A commit referencing this issue has landed:
Issue 5648 - Include lib/popupBlocker.js on Firefox

comment:4 Changed on 09/15/2017 at 11:52:10 AM by mjethani

  • Resolution set to fixed
  • Review URL(s) modified (diff)
  • Status changed from new to closed

comment:5 Changed on 09/15/2017 at 06:50:55 PM by sebastian

  • Milestone set to Adblock-Plus-for-Chrome-Opera-next

Please don't forget to set the corresponding milestone when closing issues.

Add Comment

Modify Ticket

Change Properties
as closed .
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from mjethani.
Note: See TracTickets for help on using tickets.