diff --git a/mozilla/mail/app/profile/all-thunderbird.js b/mozilla/mail/app/profile/all-thunderbird.js
index 492db81d32e..437afa3b60b 100644
--- a/mozilla/mail/app/profile/all-thunderbird.js
+++ b/mozilla/mail/app/profile/all-thunderbird.js
@@ -51,15 +51,24 @@ pref("update.app.url", "chrome://mozapps/locale/update/update.properties");
pref("update.extensions.enabled", true);
// App-specific update preferences
-pref("app.update.logEnabled", true);
-pref("app.update.enabled", false); // Whether or not app updates are enabled
-// Whether or not automated background app updates are enabled.
-pref("app.update.autoInstallEnabled", true);
-// If automatic download is enabled, whether or not the Update system should
-// automatically install the downloaded updates or just download them and prompt
-// the user to install.
-pref("app.update.autoInstallMode", 0);
+// Whether or not app updates are enabled
+pref("app.update.enabled", false);
+
+// Defines how the Application Update Service notifies the user about updates:
+//
+// AUM Set to: Minor Releases: Major Releases:
+// 0 download no prompt download no prompt
+// 1 download no prompt download no prompt if no incompatibilities
+// 2 download no prompt prompt
+// 3 prompt prompt
+//
+// See chart in nsUpdateService.js.in for more details
+//
+pref("app.update.mode", 1);
+// If set to true, the Update Service will present no UI for any event.
+pref("app.update.silent", false);
+pref("app.update.logEnabled", true);
// Default service URL for testing.
pref("app.update.url", "chrome://mozapps/locale/update/updates.properties");
diff --git a/mozilla/mail/base/content/mailWindowOverlay.js b/mozilla/mail/base/content/mailWindowOverlay.js
index 3ba51ceaf1b..0b53e3c1fe9 100644
--- a/mozilla/mail/base/content/mailWindowOverlay.js
+++ b/mozilla/mail/base/content/mailWindowOverlay.js
@@ -2535,12 +2535,20 @@ function buildHelpMenu()
var um =
Components.classes["@mozilla.org/updates/update-manager;1"].
getService(Components.interfaces.nsIUpdateManager);
- var activeUpdate = um.activeUpdate;
+
+ // Disable the UI if the update enabled pref has been locked by the
+ // administrator or if we cannot update for some other reason
+ var checkForUpdates = document.getElementById("checkForUpdates");
+ var canUpdate = updates.canUpdate;
+ checkForUpdates.setAttribute("disabled", !canUpdate);
+ if (!canUpdate)
+ return;
if (!gMessengerBundle)
gMessengerBundle = document.getElementById("bundle_messenger");
var label = gMessengerBundle.getString("updates_checkForUpdates");
+ var activeUpdate = um.activeUpdate;
if (activeUpdate)
{
if (updates.isDownloading)
@@ -2558,15 +2566,10 @@ function buildHelpMenu()
label = gMessengerBundle.getString("updates_resumeDownloadingFallback");
}
}
-
- var checkForUpdates = document.getElementById("checkForUpdates");
+
checkForUpdates.label = label;
if (um.activeUpdate && updates.isDownloading)
checkForUpdates.setAttribute("loading", "true");
else
checkForUpdates.removeAttribute("loading");
-
- // Disable the UI if the update enabled pref has been locked by the
- // administrator.
- checkForUpdates.disabled = gPrefBranch.prefIsLocked("app.update.enabled");
}
diff --git a/mozilla/mail/components/preferences/advanced.js b/mozilla/mail/components/preferences/advanced.js
index 6eb15760c31..61a05a8b1e8 100644
--- a/mozilla/mail/components/preferences/advanced.js
+++ b/mozilla/mail/components/preferences/advanced.js
@@ -74,6 +74,13 @@ var gAdvancedPane = {
{
var preference = document.getElementById("app.update.enabled");
document.getElementById("enableAutoInstall").disabled = !preference.value;
+
+ var aus =
+ Components.classes["@mozilla.org/updates/update-service;1"].
+ getService(Components.interfaces.nsIApplicationUpdateService);
+ var checkNowButton = document.getElementById("checkNowButton");
+ checkNowButton.disabled = !aus.canUpdate;
+
this.updateAutoInstallUI();
return undefined;
},
@@ -108,8 +115,9 @@ var gAdvancedPane = {
var features = "chrome,centerscreen,dialog,titlebar";
const URI_EXTENSION_UPDATE_DIALOG =
"chrome://mozapps/content/extensions/update.xul";
- var ww = Components.classes["@mozilla.org/embedcomp/window-watcher;1"]
- .getService(Components.interfaces.nsIWindowWatcher);
+ var ww =
+ Components.classes["@mozilla.org/embedcomp/window-watcher;1"].
+ getService(Components.interfaces.nsIWindowWatcher);
ww.openWindow(window, URI_EXTENSION_UPDATE_DIALOG, "", features, ary);
},
diff --git a/mozilla/mail/components/preferences/advanced.xul b/mozilla/mail/components/preferences/advanced.xul
index e903d7f5166..77411674fb0 100644
--- a/mozilla/mail/components/preferences/advanced.xul
+++ b/mozilla/mail/components/preferences/advanced.xul
@@ -59,7 +59,7 @@
-
+
@@ -198,7 +198,7 @@
accesskey="&enableAutoInstall.accesskey;"
preference="app.update.autoInstallEnabled"
onsyncfrompreference="return gAdvancedPane.updateAutoInstallUI();"/>
-
+
@@ -217,7 +217,7 @@
-