From c1ef1064698acf7b91d460ff7b9a2ea5529f5574 Mon Sep 17 00:00:00 2001 From: Kushagra Gour Date: Fri, 13 May 2016 02:30:25 +0530 Subject: [PATCH] remove tab permission. --- src/eventPage.js | 21 +-------------------- src/manifest.json | 9 +++++---- 2 files changed, 6 insertions(+), 24 deletions(-) diff --git a/src/eventPage.js b/src/eventPage.js index 3422c4a..036d97b 100644 --- a/src/eventPage.js +++ b/src/eventPage.js @@ -1,22 +1,3 @@ -chrome.tabs.onCreated.addListener(function (tab) { - - console.log('created', arguments) - if (tab.url === 'chrome://newtab/') { - chrome.tabs.update(tab.id, { - url: chrome.extension.getURL('index.html') - }, function callback() { - console.log('ho gaya'); - }); - } - -}); - -chrome.tabs.onUpdated.addListener(function () { - - console.log('updated', arguments) - -}); - chrome.browserAction.onClicked.addListener(function(activeTab) { chrome.tabs.create({ url: chrome.extension.getURL('index.html'), selected: true }); -}); +}); \ No newline at end of file diff --git a/src/manifest.json b/src/manifest.json index 4b578e5..9fb4c31 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -5,18 +5,19 @@ "description": "Convert new tabs into an offline playground for your web experiments", "homepage_url": "https://kushagragour.in/lab/web-maker", "permissions": [ - "storage", - "tabs" + "storage" ], + "chrome_url_overrides" : { + "newtab": "index.html" + }, "browser_action": { - "default_title": "Start Web Maker", + "default_title": "Web Maker", "default_icon": "icon-16.png" }, "background": { "scripts": [ "eventPage.js" ], "persistent": false }, - "content_security_policy": "script-src 'self' 'unsafe-eval'; object-src 'self'", "icons": { "16": "icon-16.png", "48": "icon-48.png"