From 36fd9e8369e46d3d9fc3d1c6a7f81efc10050750 Mon Sep 17 00:00:00 2001 From: NeverDecaf Date: Thu, 28 Nov 2019 08:53:24 -0500 Subject: [PATCH] add option to ignore specific extensions, closes #5 --- Chromium Web Store.crx | Bin 21729 -> 22380 bytes src/manifest.json | 2 +- src/options.html | 4 +- src/scripts/background.js | 200 ++++++++++++++++++++------------------ src/scripts/options.js | 69 ++++++++----- src/scripts/popup.js | 56 ++++++----- src/sheets/options.css | 7 ++ updates.xml | 2 +- 8 files changed, 196 insertions(+), 144 deletions(-) diff --git a/Chromium Web Store.crx b/Chromium Web Store.crx index fbe4be71df2f8cde73cd8c610358c05de71ce85c..ece70eb8f6946fa35eeb1ce5f3992c575249a954 100644 GIT binary patch delta 6724 zcmZvgWl$SH+pa@!3-0dH7AamdxCbvTrMMHcK!X%71PJbK#VM}AwKx=ar%;L&DLsA9 zH)p{oic#$#;PkDIyP!Jf)jNU`{Oy-8 zSlWvPL)ao>T=~;sFh>IhcaF(UJt==E$CG?B7w+=|yQkF=$t#0H`>7>&s>QLNxklnL zH00o^I0I`yY|)kJdDgKTvw;ybmF2Eo&_rAz)c6|NDnD6X0df2@{_oLi14XoT7r zn@%tsw5CiJ?M_hKn$g3*A?iw3AaDe<=thVGm9S(L0wIsqrviu=ARR1Iois?Z@)rXq zgEg>Fna{0tlCXs!Osq8bhy07p|6y1cQB0Og)l?+-;oFkh2>&44cZ?6UzD2txKlFfJZ1^nFj zx$S~4srQ4bMWaXG7b;g%aIA5NA2pje_QacP2+-fY`m)Dk2Zb@H3yvq*cI-Y3CIuQf z33uhMv^+a0xCkwChM{_{?c|E3ROrYIczge;am zNTd!sw?^RvNmUC4g8s`evKm83?{YR@b`_uduq~m%1#fxye zrfAvx9W)o{`hyL%#`^qeTAOIX3fkbAgrFqWPfZyj8%8XxJyn%6zz_j&O@Okbv7|2s zZc(R8Bx5zqCZmguCHiJr$Lb|YczhkJpHds6d;t;TD(ui;I2_ndi+O*DL&Bs+P~msX z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zwU?Z9|3l-wf!r<|1Yet_V#v7(sf2NQADg_{2`$pdCa1k25G2& zD7s`vy+#(LwSaGqy)~H^E4p*TcHb!LqqI)~L~<73whFAZU7^|^8McydVC z*B8GoC@KjehPbVx%dJ|hOui`h7}6akyygg~b|Z^s6e|7<3vLwhl*dcwSdY))zjbXD zvpedZk;y!-J^>dQ-yXmC9&OZ_mZUy5%>tFO4+C#zoe}-pgET3zobdi9ca_l-B>J!1 z1`(vE4je^{=!pVb5FmYF;4(r?UkHeaaMh=0`tNW60HFNK-9Po0#=pgngXqSiM)c@& zf!K)RX#x!veO~%47ot@B7Y$T uLfVKAbS3r|k|RQl_(9B4|AGU5p}Fk8Ab~MI=ve+=P{)`Gn^yCmFa8If>|9X* diff --git a/src/manifest.json b/src/manifest.json index 914d77a..a8e1a09 100644 --- a/src/manifest.json +++ b/src/manifest.json @@ -2,7 +2,7 @@ "author": "NeverDecaf", "manifest_version": 2, "name": "Chromium Web Store", - "version": "0.7.1", + "version": "0.8.0", "key": "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAqF/d41Q7agjkUzYq8ZGbQr8XW8mmEIMXOnR1uCTnYLL+Dm9Z+LO50xZukOISNy6zFxpI8ts/OGLsm+I2x9+UprUU4/EVdmxuwegFE6NBoEhHoRNYY0gbXZkaU8YY/XwzjVY/k18DDhl5NYPEnF6uq4Oyidg+xtd3W4+iGYczuOLER1Tp5y614zOTphcvFYhvUkCijQ6HT1TtRq/34SlFoRQqo4SFiLriK451xWIcfwiMLIekWrdoQa1v8dqIlMA3r6CKc0QykJpSYbiyormWiZ0hl2HLpkZ85mD9V0eDQ5RCtb6vkybK7INcq4yKQV4YkXhr9NpX9U4re4dlFQjEJQIDAQAB", "description": "Allow installing/updating extensions from chrome web store on chromium based browsers. Click badge to check for updates.", "permissions": [ diff --git a/src/options.html b/src/options.html index a967be6..ae36451 100644 --- a/src/options.html +++ b/src/options.html @@ -23,7 +23,9 @@

Update Options

Check for updates to non-web store extensions +

Ignored Extensions

+
- + \ No newline at end of file diff --git a/src/scripts/background.js b/src/scripts/background.js index bd21f10..e563354 100644 --- a/src/scripts/background.js +++ b/src/scripts/background.js @@ -1,90 +1,102 @@ chrome.browserAction.setBadgeBackgroundColor({ color: '#F00' }); + function updateBadge(modified_ext_id = null) { - chrome.storage.sync.get({ - "auto_update": true, - "check_store_apps": true, - "check_external_apps": true - }, function (settings) { - if (settings.auto_update) { - chrome.management.getAll(function (e) { - var chromeVersion = /Chrome\/([0-9.]+)/.exec(navigator.userAgent)[1]; - var webstoreUrl = 'clients2.google.com/service/update2/crx'; - var updateUrl = 'https://clients2.google.com/service/update2/crx?response=updatecheck&acceptformat=crx2,crx3&prodversion=' + chromeVersion; - var installed_versions = {}; - var updateUrls = []; - e.forEach(function (ex) { - if (ex.updateUrl) { - if (webstoreUrl == ex.updateUrl.replace(/^(?:https?:\/\/)?/i, "")) { - updateUrl += '&x=id%3D' + ex.id + '%26uc'; - } else { - updateUrls.push(ex.updateUrl); - } - installed_versions[ex.id] = ex; - } - }); - updateUrls.push(updateUrl); + chrome.management.getAll(function (e) { + var default_options = { + "auto_update": true, + "check_store_apps": true, + "check_external_apps": true + }; + var chromeVersion = /Chrome\/([0-9.]+)/.exec(navigator.userAgent)[1]; + var webstoreUrl = 'clients2.google.com/service/update2/crx'; + var updateUrl = 'https://clients2.google.com/service/update2/crx?response=updatecheck&acceptformat=crx2,crx3&prodversion=' + chromeVersion; + var installed_versions = {}; + var updateUrls = []; + e.forEach(function (ex) { + if (ex.updateUrl) { + if (webstoreUrl == ex.updateUrl.replace(/^(?:https?:\/\/)?/i, "")) { + updateUrl += '&x=id%3D' + ex.id + '%26uc'; + } else { + updateUrls.push(ex.updateUrl); + } + installed_versions[ex.id] = ex; + } + default_options[ex.id] = false; + }); + updateUrls.push(updateUrl); - function getNewXhr() { - var xhttp = new XMLHttpRequest(); - xhttp.onreadystatechange = function () { - if (this.readyState == 4) { - if (this.status == 200) { - xmlDoc = this.responseXML; - var updates = xmlDoc.getElementsByTagName('app'); - let updateCount = 0; - for (var i = 0; i < updates.length; i++) { - if (updateCheck = updates[i].querySelector("*")) { - var updatever = updateCheck.getAttribute('version'); - var appid = updates[i].getAttribute('appid'); - var is_webstore = xhttp._url == updateUrl; - if (updatever && installed_versions[appid].version != updatever) { - updateCount++; + chrome.storage.sync.get(default_options, function (settings) { + if (settings.auto_update) { + function getNewXhr() { + var xhttp = new XMLHttpRequest(); + xhttp.onreadystatechange = function () { + if (this.readyState == 4) { + if (this.status == 200) { + xmlDoc = this.responseXML; + var updates = xmlDoc.getElementsByTagName('app'); + let updateCount = 0; + for (var i = 0; i < updates.length; i++) { + if (updateCheck = updates[i].querySelector("*")) { + var updatever = updateCheck.getAttribute('version'); + var appid = updates[i].getAttribute('appid'); + var is_webstore = xhttp._url == updateUrl; + if (updatever && !settings[appid] && installed_versions[appid].version != updatever) { + updateCount++; + } } } - } - chrome.browserAction.getBadgeText({}, function (currentText) { - if (currentText != '?') { - if (!currentText) { - if (updateCount) + chrome.browserAction.getBadgeText({}, function (currentText) { + if (currentText != '?') { + if (!currentText) { + if (updateCount) + chrome.browserAction.setBadgeText({ + text: '' + updateCount + }); + } else chrome.browserAction.setBadgeText({ - text: '' + updateCount + text: parseInt(updateCount) + parseInt(currentText) + '' }); - } else - chrome.browserAction.setBadgeText({ - text: parseInt(updateCount) + parseInt(currentText) + '' - }); - } - }); - } else { - if (is_webstore) - chrome.browserAction.setBadgeText({ - text: "?" + } }); + } else { + if (is_webstore) + chrome.browserAction.setBadgeText({ + text: "?" + }); + } } - } + }; + xhttp.overrideMimeType('application/xml'); + return xhttp; }; - xhttp.overrideMimeType('application/xml'); - return xhttp; - }; - chrome.browserAction.setBadgeText({ - text: '' - }); - updateUrls.forEach(function (uurl) { - if ((updateUrl == uurl && settings.check_store_apps) || (updateUrl != uurl && settings.check_external_apps)) { - xhr = getNewXhr(); - xhr.open("GET", uurl, true); - xhr._url = uurl; - xhr.send(); - } - }); - }); - } + chrome.browserAction.setBadgeText({ + text: '' + }); + updateUrls.forEach(function (uurl) { + if ((updateUrl == uurl && settings.check_store_apps) || (updateUrl != uurl && settings.check_external_apps)) { + xhr = getNewXhr(); + xhr.open("GET", uurl, true); + xhr._url = uurl; + xhr.send(); + } + }); + } + }); }); }; chrome.management.onInstalled.addListener(function (ext) { updateBadge(ext.id); + console.log(ext); +}); +chrome.management.onEnabled.addListener(function (ext) { + console.log("enabled"); + console.log(ext); +}); +chrome.management.onDisabled.addListener(function (ext) { + console.log("disabled"); + console.log(ext); }); chrome.management.onUninstalled.addListener(function (ext) { updateBadge(ext.id); @@ -102,29 +114,31 @@ chrome.alarms.onAlarm.addListener(function (alarm) { function updateAll(info) { if (info.menuItemId == 'updateAll') { - chrome.storage.sync.get({ - "auto_update": true, - "check_store_apps": true, - "check_external_apps": true - }, function (settings) { - chrome.management.getAll(function (e) { - var chromeVersion = /Chrome\/([0-9.]+)/.exec(navigator.userAgent)[1]; - var webstoreUrl = 'clients2.google.com/service/update2/crx'; - var updateUrl = 'https://clients2.google.com/service/update2/crx?response=updatecheck&acceptformat=crx2,crx3&prodversion=' + chromeVersion; - var installed_versions = {}; - var updateUrls = []; - e.forEach(function (ex) { - if (ex.updateUrl) { - if (webstoreUrl == ex.updateUrl.replace(/^(?:https?:\/\/)?/i, "")) { - updateUrl += '&x=id%3D' + ex.id + '%26uc'; - } else { - updateUrls.push(ex.updateUrl); - } - installed_versions[ex.id] = ex; + chrome.management.getAll(function (e) { + var default_options = { + "auto_update": true, + "check_store_apps": true, + "check_external_apps": true + }; + var chromeVersion = /Chrome\/([0-9.]+)/.exec(navigator.userAgent)[1]; + var webstoreUrl = 'clients2.google.com/service/update2/crx'; + var updateUrl = 'https://clients2.google.com/service/update2/crx?response=updatecheck&acceptformat=crx2,crx3&prodversion=' + chromeVersion; + var installed_versions = {}; + var updateUrls = []; + e.forEach(function (ex) { + if (ex.updateUrl) { + if (webstoreUrl == ex.updateUrl.replace(/^(?:https?:\/\/)?/i, "")) { + updateUrl += '&x=id%3D' + ex.id + '%26uc'; + } else { + updateUrls.push(ex.updateUrl); } - }); - updateUrls.push(updateUrl); + installed_versions[ex.id] = ex; + } + default_options[ex.id] = false; + }); + updateUrls.push(updateUrl); + chrome.storage.sync.get(default_options, function (settings) { function getNewXhr() { var xhttp = new XMLHttpRequest(); xhttp.onreadystatechange = function () { @@ -138,7 +152,7 @@ function updateAll(info) { var updatever = updateCheck.getAttribute('version'); var appid = updates[i].getAttribute('appid'); var is_webstore = xhttp._url == updateUrl; - if (updatever && installed_versions[appid].version != updatever) { + if (updatever && !settings[appid] && installed_versions[appid].version != updatever) { updateCount++; let crx_url = updateCheck.getAttribute('codebase'); window.open(crx_url, '_blank'); diff --git a/src/scripts/options.js b/src/scripts/options.js index 05b5c7c..d986b40 100644 --- a/src/scripts/options.js +++ b/src/scripts/options.js @@ -1,25 +1,50 @@ -const default_options = { - "auto_update": true, - "check_store_apps": true, - "check_external_apps": true -}; -function restore_options() { - chrome.storage.sync.get(default_options, function (items) { - console.log(items); - for (const [setting, checked] of Object.entries(items)) { - let node = document.getElementById(setting); - node.checked = checked; - node.addEventListener("click", e => { - const checked = e.target.checked; - chrome.storage.sync.set({ - [e.target.id]: checked - }, function () { - if (chrome.runtime.lastError) { - node.checked = !checked; - } +function load_options() { + var maindiv = document.getElementById('updatetoggle'); + var default_options = { + "auto_update": true, + "check_store_apps": true, + "check_external_apps": true + }; + chrome.management.getAll(function (e) { + e.forEach(function (ex) { + label = document.createElement('label'); + label.setAttribute('title', 'Never check for updates to this extension'); + span = document.createElement('span'); + div = document.createElement('div'); + img = document.createElement('img'); + input = document.createElement('input'); + input.setAttribute('type', 'checkbox'); + input.setAttribute('id', ex.id); + img.setAttribute('alt', ex.name); + if (ex.icons) + img.setAttribute('src', 'chrome://extension-icon/' + ex.id + '/' + ex.icons[0].size + '/0'); + else + img.setAttribute('src', 'chrome://extension-icon/' + ex.id + '/16/0'); + span.innerHTML = ex.name; + label.appendChild(input); + label.appendChild(img); + label.appendChild(span); + div.appendChild(label); + maindiv.appendChild(div); + default_options[ex.id] = false; + }); + chrome.storage.sync.get(default_options, function (items) { + for (const [setting, checked] of Object.entries(items)) { + let node = document.getElementById(setting); + node.checked = checked; + node.addEventListener("click", e => { + const checked = e.target.checked; + chrome.storage.sync.set({ + [e.target.id]: checked + }, function () { + if (chrome.runtime.lastError) { + node.checked = !checked; + } + }); }); - }); - } + } + }); }); } -document.addEventListener('DOMContentLoaded', restore_options); \ No newline at end of file + +document.addEventListener('DOMContentLoaded', load_options); \ No newline at end of file diff --git a/src/scripts/popup.js b/src/scripts/popup.js index c48ef03..c4f5824 100644 --- a/src/scripts/popup.js +++ b/src/scripts/popup.js @@ -7,30 +7,33 @@ var alluptodate = document.createElement('h1'); alluptodate.innerHTML = 'Checking for updates...'; container.appendChild(alluptodate); container.appendChild(appcontainer); -chrome.storage.sync.get({ - "auto_update": true, - "check_store_apps": true, - "check_external_apps": true -}, function (settings) { - if (!settings.check_store_apps && !settings.check_external_apps) - alluptodate.innerHTML = 'All extensions are up to date!'; - chrome.management.getAll(function (e) { - var chromeVersion = /Chrome\/([0-9.]+)/.exec(navigator.userAgent)[1]; - var webstoreUrl = 'clients2.google.com/service/update2/crx'; - var updateUrl = 'https://clients2.google.com/service/update2/crx?response=updatecheck&acceptformat=crx2,crx3&prodversion=' + chromeVersion; - var installed_versions = {}; - var updateUrls = []; - e.forEach(function (ex) { - if (ex.updateUrl) { - if (webstoreUrl == ex.updateUrl.replace(/^(?:https?:\/\/)?/i, "")) { - updateUrl += '&x=id%3D' + ex.id + '%26uc'; - } else { - updateUrls.push(ex.updateUrl); - } - installed_versions[ex.id] = ex; +chrome.management.getAll(function (e) { + var default_options = { + "auto_update": true, + "check_store_apps": true, + "check_external_apps": true + }; + var chromeVersion = /Chrome\/([0-9.]+)/.exec(navigator.userAgent)[1]; + var webstoreUrl = 'clients2.google.com/service/update2/crx'; + var updateUrl = 'https://clients2.google.com/service/update2/crx?response=updatecheck&acceptformat=crx2,crx3&prodversion=' + chromeVersion; + var installed_versions = {}; + var updateUrls = []; + e.forEach(function (ex) { + if (ex.updateUrl) { + if (webstoreUrl == ex.updateUrl.replace(/^(?:https?:\/\/)?/i, "")) { + updateUrl += '&x=id%3D' + ex.id + '%26uc'; + } else { + updateUrls.push(ex.updateUrl); } - }); - updateUrls.push(updateUrl); + installed_versions[ex.id] = ex; + } + default_options[ex.id] = false; + }); + updateUrls.push(updateUrl); + chrome.storage.sync.get(default_options, function (settings) { + if (!settings.check_store_apps && !settings.check_external_apps) + alluptodate.innerHTML = 'All extensions are up to date!'; + function getNewXhr() { var xhttp = new XMLHttpRequest(); xhttp.onreadystatechange = function () { @@ -44,7 +47,7 @@ chrome.storage.sync.get({ var updatever = updateCheck.getAttribute('version'); var appid = updates[i].getAttribute('appid'); var is_webstore = xhttp._url == updateUrl; - if (updatever && installed_versions[appid].version != updatever) { + if (updatever && !settings[appid] && installed_versions[appid].version != updatever) { updateCount++; var li = document.createElement('li'); li.setAttribute('data-enabled', installed_versions[appid].enabled ? 'true' : 'false'); @@ -70,7 +73,7 @@ chrome.storage.sync.get({ li.appendChild(storepage); } li.setAttribute('crx_url', updateCheck.getAttribute('codebase')); - let crx_url = updateCheck.getAttribute('codebase'); + let crx_url = updateCheck.getAttribute('codebase'); li.addEventListener("click", function (evt) { if (evt.target.tagName != 'A') window.open(crx_url); @@ -80,7 +83,6 @@ chrome.storage.sync.get({ } } } - chrome.browserAction.getBadgeText({}, function (currentText) { if (currentText != '?') { if (!currentText) { @@ -121,6 +123,8 @@ chrome.storage.sync.get({ if (completed == 0) alluptodate.innerHTML = 'All extensions are up to date!'; }; + } else { + completed--; } }); }); diff --git a/src/sheets/options.css b/src/sheets/options.css index 63519a9..8a3cdff 100644 --- a/src/sheets/options.css +++ b/src/sheets/options.css @@ -22,3 +22,10 @@ label > span { margin-left: 0.3em; user-select: none; } + +label > img { + flex: 0 0 auto; + margin: auto 4px auto 8px; + width: 16px; + height: 16px; +} \ No newline at end of file diff --git a/updates.xml b/updates.xml index 38dddcb..177e96a 100644 --- a/updates.xml +++ b/updates.xml @@ -1,6 +1,6 @@ - + \ No newline at end of file