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

Unified Diff: lib/notificationHelper.js

Issue 29567798: Noissue - Replace ext.pages.open with tabs.create (Closed) Base URL: https://hg.adblockplus.org/adblockpluschrome/
Patch Set: Remove ext.pages.open implementation Created Oct. 8, 2017, 9:45 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ext/background.js ('k') | lib/subscriptionInit.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/notificationHelper.js
===================================================================
--- a/lib/notificationHelper.js
+++ b/lib/notificationHelper.js
@@ -100,29 +100,31 @@
return buttons;
}
function openNotificationLinks()
{
if (activeNotification.links)
{
for (let link of activeNotification.links)
- ext.pages.open(Utils.getDocLink(link));
+ chrome.tabs.create({url: Utils.getDocLink(link)});
}
}
function notificationButtonClick(buttonIndex)
{
if (!(activeButtons && buttonIndex in activeButtons))
return;
switch (activeButtons[buttonIndex].type)
{
case "link":
- ext.pages.open(Utils.getDocLink(activeNotification.links[buttonIndex]));
+ chrome.tabs.create({
+ url: Utils.getDocLink(activeNotification.links[buttonIndex])
+ });
break;
case "open-all":
openNotificationLinks();
break;
case "configure":
Prefs.notifications_showui = true;
showOptions(page =>
{
« no previous file with comments | « ext/background.js ('k') | lib/subscriptionInit.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld