From e48f2f1cdb5b1a1d0ab28505e0b03d7d41c27091 Mon Sep 17 00:00:00 2001 From: aykutcevik Date: Sat, 24 Feb 2018 22:17:37 +0100 Subject: [PATCH 1/4] added application info --- manifest.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index 45302c0..98e48ad 100644 --- a/manifest.json +++ b/manifest.json @@ -29,5 +29,10 @@ "default_popup": "html/popup.html" }, - "author": "Aykut Çevik" + "author": "Aykut Çevik", + "applications": { + "gecko": { + "id": "idnsafe@aykutcevik.com" + } + } } \ No newline at end of file From f5e4f03cbe8fddd089592668fb5e74994cd5749c Mon Sep 17 00:00:00 2001 From: aykutcevik Date: Sat, 24 Feb 2018 22:37:11 +0100 Subject: [PATCH 2/4] added fixes for Firefox mobile on Android, #6 --- html/options.html | 1 + html/popup.html | 1 + js/background.js | 24 ++++++++++++++++++++---- 3 files changed, 22 insertions(+), 4 deletions(-) diff --git a/html/options.html b/html/options.html index 40ef57f..1e9ce62 100644 --- a/html/options.html +++ b/html/options.html @@ -10,6 +10,7 @@ +
diff --git a/html/popup.html b/html/popup.html index d84884f..1fc7c56 100644 --- a/html/popup.html +++ b/html/popup.html @@ -10,6 +10,7 @@ + diff --git a/js/background.js b/js/background.js index eddaef0..3b28b04 100644 --- a/js/background.js +++ b/js/background.js @@ -113,11 +113,27 @@ function whitelistDomains(domains) { function updateTabIcon(tabId) { if (blockedTabs[tabId]) { - browser.browserAction.setIcon({tabId: tabId, path: "../img/icon_red_48.png"}); - browser.browserAction.setBadgeText({tabId: tabId, "text": "" + blockedTabs[tabId]}); + if (browser.browserAction.setIcon !== undefined) { + browser.browserAction.setIcon({tabId: tabId, path: "../img/icon_red_48.png"}); + browser.browserAction.setBadgeText({tabId: tabId, "text": "" + blockedTabs[tabId]}); + } + if (browser.browserAction.setTitle !== undefined ) { + browser.browserAction.setTitle({ + tabId: tabId, + title: browser.runtime.getManifest().name + " (BLOCKED)" + }); + } } else { - browser.browserAction.setIcon({tabId: tabId, path: "../img/icon_48.png"}); - browser.browserAction.setBadgeText({tabId: tabId, "text": ""}); + if (browser.browserAction.setIcon !== undefined) { + browser.browserAction.setIcon({tabId: tabId, path: "../img/icon_48.png"}); + browser.browserAction.setBadgeText({tabId: tabId, "text": ""}); + } + if (browser.browserAction.setTitle !== undefined ) { + browser.browserAction.setTitle({ + tabId: tabId, + title: browser.runtime.getManifest().name + }); + } } } From dafc32a900230b82b5bd081277a56e248a3140aa Mon Sep 17 00:00:00 2001 From: aykutcevik Date: Sat, 24 Feb 2018 23:03:55 +0100 Subject: [PATCH 3/4] reverted missing icon --- manifest.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index 98e48ad..e72e6ec 100644 --- a/manifest.json +++ b/manifest.json @@ -3,6 +3,7 @@ "version": "1.4", "manifest_version": 2, "icons": { + "48": "img/icon_48.png", "128": "img/icon_128.png", "512": "img/icon_512.png" }, @@ -26,7 +27,7 @@ ], "browser_action": { "default_title": "IDN Safe", - + "default_icon": "img/icon_48.png", "default_popup": "html/popup.html" }, "author": "Aykut Çevik", From 108bac528358f6aa0467bf43637e8af8f442da74 Mon Sep 17 00:00:00 2001 From: aykutcevik Date: Sat, 24 Feb 2018 23:06:33 +0100 Subject: [PATCH 4/4] fixed Firefox id --- manifest.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index e72e6ec..f773929 100644 --- a/manifest.json +++ b/manifest.json @@ -33,7 +33,7 @@ "author": "Aykut Çevik", "applications": { "gecko": { - "id": "idnsafe@aykutcevik.com" + "id": "{6e54c8db-b553-4aad-a2e2-de3cda802eca}" } } } \ No newline at end of file