From 7487cb290e0de867139c8e50d28cfa90cee6afbd Mon Sep 17 00:00:00 2001 From: Fedor Date: Thu, 17 Sep 2020 09:01:45 +0300 Subject: [PATCH] Remove plugin checking code leftovers. --- application/palemoon/app/profile/mypal.js | 3 --- .../palemoon/base/content/browser-plugins.js | 12 +----------- .../palemoon/components/nsBrowserGlue.js | 18 ------------------ .../chrome/mozapps/extensions/extensions.dtd | 4 ---- .../mozapps/extensions/content/extensions.js | 14 +------------- .../mozapps/extensions/content/extensions.xml | 4 +--- .../mozapps/extensions/content/extensions.xul | 10 ---------- 7 files changed, 3 insertions(+), 62 deletions(-) diff --git a/application/palemoon/app/profile/mypal.js b/application/palemoon/app/profile/mypal.js index 57e7dab09..4cd31c216 100644 --- a/application/palemoon/app/profile/mypal.js +++ b/application/palemoon/app/profile/mypal.js @@ -681,9 +681,6 @@ pref("plugins.hide_infobar_for_outdated_plugin", false); // Pale Moon:pref to always show the plugin indicator or not (default=false) pref("plugins.always_show_indicator", false); -pref("plugins.update.url", "https://aus.palemoon.org/plugincheck/"); -pref("plugins.update.notifyUser", false); - //Enable tri-state option (Always/Never/Ask) pref("plugins.click_to_play", true); diff --git a/application/palemoon/base/content/browser-plugins.js b/application/palemoon/base/content/browser-plugins.js index bb895372c..ed255b72f 100644 --- a/application/palemoon/base/content/browser-plugins.js +++ b/application/palemoon/base/content/browser-plugins.js @@ -323,12 +323,6 @@ var gPluginHandler = { BrowserOpenAddonsMgr("addons://list/plugin"); }, - // Callback for user clicking on the link in a click-to-play plugin - // (where the plugin has an update) - openPluginUpdatePage: function(aEvent) { - openURL(Services.urlFormatter.formatURLPref("plugins.update.url")); - }, - // Callback for user clicking a "reload page" link reloadPage: function(browser) { browser.reload(); @@ -510,11 +504,7 @@ var gPluginHandler = { } let url; - // TODO: allow the blocklist to specify a better link, bug 873093 - if (pluginInfo.blocklistState == Ci.nsIBlocklistService.STATE_VULNERABLE_UPDATE_AVAILABLE) { - url = Services.urlFormatter.formatURLPref("plugins.update.url"); - } - else if (pluginInfo.blocklistState != Ci.nsIBlocklistService.STATE_NOT_BLOCKED) { + if (pluginInfo.blocklistState != Ci.nsIBlocklistService.STATE_NOT_BLOCKED) { url = Services.blocklist.getPluginBlocklistURL(pluginInfo.pluginTag); } pluginInfo.detailsLink = url; diff --git a/application/palemoon/components/nsBrowserGlue.js b/application/palemoon/components/nsBrowserGlue.js index 01740f8ca..72990511c 100644 --- a/application/palemoon/components/nsBrowserGlue.js +++ b/application/palemoon/components/nsBrowserGlue.js @@ -57,9 +57,6 @@ XPCOMUtils.defineLazyGetter(this, "gBrowserBundle", function() { return Services.strings.createBundle('chrome://browser/locale/browser.properties'); }); -const PREF_PLUGINS_NOTIFYUSER = "plugins.update.notifyUser"; -const PREF_PLUGINS_UPDATEURL = "plugins.update.url"; - // We try to backup bookmarks at idle times, to avoid doing that at shutdown. // Number of idle seconds before trying to backup bookmarks. 15 minutes. const BOOKMARKS_BACKUP_IDLE_TIME = 15 * 60; @@ -880,21 +877,6 @@ BrowserGlue.prototype = { } }, - _showPluginUpdatePage: function() { - // Pale Moon: disable this functionality from BrowserGlue, people are - // already notified if they visit a page with an outdated plugin, and - // they can check properly from the plugins page as well. - -// Services.prefs.setBoolPref(PREF_PLUGINS_NOTIFYUSER, false); -// -// var formatter = Cc["@mozilla.org/toolkit/URLFormatterService;1"]. -// getService(Ci.nsIURLFormatter); -// var updateUrl = formatter.formatURLPref(PREF_PLUGINS_UPDATEURL); -// -// var win = this.getMostRecentBrowserWindow(); -// win.openUILinkIn(updateUrl, "tab"); - }, - /** * Initialize Places * - imports the bookmarks html file if bookmarks database is empty, try to diff --git a/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd b/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd index b5086032c..cd2ff803f 100644 --- a/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd +++ b/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd @@ -40,10 +40,6 @@ - - - - diff --git a/toolkit/mozapps/extensions/content/extensions.js b/toolkit/mozapps/extensions/content/extensions.js index 9576e9a3b..2ca3898f1 100644 --- a/toolkit/mozapps/extensions/content/extensions.js +++ b/toolkit/mozapps/extensions/content/extensions.js @@ -809,15 +809,6 @@ var gViewController = { } }, -/* Plugincheck service is currently N/A for Pale Moon - cmd_pluginCheck: { - isEnabled: function cmd_pluginCheck_isEnabled() true, - doCommand: function cmd_pluginCheck_doCommand() { - openURL(Services.urlFormatter.formatURLPref("plugins.update.url")); - } - }, -*/ - cmd_toggleAutoUpdateDefault: { isEnabled: function cmd_toggleAutoUpdateDefault_isEnabled() true, doCommand: function cmd_toggleAutoUpdateDefault_doCommand() { @@ -3028,10 +3019,7 @@ var gDetailView = { "details.notification.outdated", [this._addon.name], 1 ); - var warningLink = document.getElementById("detail-warning-link"); - warningLink.value = gStrings.ext.GetStringFromName("details.notification.outdated.link"); - warningLink.href = Services.urlFormatter.formatURLPref("plugins.update.url"); - warningLink.hidden = false; + document.getElementById("detail-warning-link").hidden = true; } else if (this._addon.blocklistState == Ci.nsIBlocklistService.STATE_VULNERABLE_UPDATE_AVAILABLE) { this.node.setAttribute("notification", "error"); document.getElementById("detail-error").textContent = gStrings.ext.formatStringFromName( diff --git a/toolkit/mozapps/extensions/content/extensions.xml b/toolkit/mozapps/extensions/content/extensions.xml index 9c8fda8ed..28feb1969 100644 --- a/toolkit/mozapps/extensions/content/extensions.xml +++ b/toolkit/mozapps/extensions/content/extensions.xml @@ -1328,9 +1328,7 @@ "notification.outdated", [this.mAddon.name], 1 ); - this._warningLink.value = gStrings.ext.GetStringFromName("notification.outdated.link"); - this._warningLink.href = Services.urlFormatter.formatURLPref("plugins.update.url"); - this._warningLink.hidden = false; + this._warningLink.hidden = true; this._warningBtn.hidden = true; } else if (!isUpgrade && this.mAddon.blocklistState == Ci.nsIBlocklistService.STATE_VULNERABLE_UPDATE_AVAILABLE) { this.setAttribute("notification", "error"); diff --git a/toolkit/mozapps/extensions/content/extensions.xul b/toolkit/mozapps/extensions/content/extensions.xul index 292ecf8d3..70ce55fa2 100644 --- a/toolkit/mozapps/extensions/content/extensions.xul +++ b/toolkit/mozapps/extensions/content/extensions.xul @@ -88,7 +88,6 @@ - @@ -355,15 +354,6 @@ -