diff --git a/mozilla/mailnews/base/prefs/resources/content/accountUtils.js b/mozilla/mailnews/base/prefs/resources/content/accountUtils.js
index 04928d550eb..943f3a9004e 100644
--- a/mozilla/mailnews/base/prefs/resources/content/accountUtils.js
+++ b/mozilla/mailnews/base/prefs/resources/content/accountUtils.js
@@ -136,6 +136,9 @@ function verifyAccounts(wizardcallback) {
try {
var am = Components.classes[accountManagerContractID].getService(Components.interfaces.nsIMsgAccountManager);
+ // migrate quoting preferences from global to per account
+ migrateGlobalQuotingPrefs(am.allIdentities);
+
var accounts = am.accounts;
// as long as we have some accounts, we're fine.
@@ -251,3 +254,39 @@ function loadInboxForNewAccount()
gNewAccountToLoad = null;
}
}
+
+function migrateGlobalQuotingPrefs(allIdentities)
+{
+ // if reply_on_top and auto_quote exist then, if non-default
+ // migrate and delete, if default just delete.
+ var reply_on_top = 0;
+ var auto_quote = true;
+ var quotingPrefs = 0;
+ try {
+ var prefService = Components.classes["@mozilla.org/preferences-service;1"]
+ .getService(Components.interfaces.nsIPrefService);
+ var pref = prefService.getBranch(null);
+ quotingPrefs = pref.getIntPref("mailnews.quotingPrefs.version");
+ } catch (ex) {}
+
+ // If the quotingPrefs version is 0 then we need to migrate our preferences
+ if (quotingPrefs == 0) {
+ try {
+ reply_on_top = pref.getIntPref("mailnews.reply_on_top");
+ auto_quote = pref.getBoolPref("mail.auto_quote");
+ } catch (ex) {}
+
+ if (!auto_quote || reply_on_top) {
+ var numIdentities = allIdentities.Count();
+ var identity = null;
+ for (var j = 0; j < numIdentities; j++) {
+ identity = allIdentities.QueryElementAt(j, Components.interfaces.nsIMsgIdentity);
+ if (identity.valid) {
+ identity.autoQuote = auto_quote;
+ identity.replyOnTop = reply_on_top;
+ }
+ }
+ }
+ pref.setIntPref("mailnews.quotingPrefs.version", 1);
+ }
+}
diff --git a/mozilla/mailnews/base/prefs/resources/content/am-addressing.js b/mozilla/mailnews/base/prefs/resources/content/am-addressing.js
index dc1b6c0de20..96d16361ae7 100644
--- a/mozilla/mailnews/base/prefs/resources/content/am-addressing.js
+++ b/mozilla/mailnews/base/prefs/resources/content/am-addressing.js
@@ -11,6 +11,7 @@ function onInit()
{
setupDirectoriesList();
enabling();
+ quoteEnabling();
}
function onPreInit(account, accountValues)
@@ -101,3 +102,18 @@ function onSave()
break;
}
}
+
+function quoteEnabling()
+{
+ var quotebox = document.getElementById("thenBox");
+ var quotecheck = document.getElementById("identity.autoQuote");
+ if (quotecheck.checked && !quotecheck.disabled) {
+ quotebox.firstChild.removeAttribute("disabled");
+ quotebox.lastChild.removeAttribute("disabled");
+ }
+ else {
+ quotebox.firstChild.setAttribute("disabled", "true");
+ quotebox.lastChild.setAttribute("disabled", "true");
+ }
+}
+
diff --git a/mozilla/mailnews/base/prefs/resources/content/am-addressing.xul b/mozilla/mailnews/base/prefs/resources/content/am-addressing.xul
index 226a52aaa06..fe764ca8712 100644
--- a/mozilla/mailnews/base/prefs/resources/content/am-addressing.xul
+++ b/mozilla/mailnews/base/prefs/resources/content/am-addressing.xul
@@ -47,6 +47,7 @@ Contributors:
+
&addressingText.label;
@@ -61,4 +62,35 @@ Contributors:
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/mozilla/mailnews/base/prefs/resources/content/am-main.xul b/mozilla/mailnews/base/prefs/resources/content/am-main.xul
index 31fd3645458..7ad0fdf08c8 100644
--- a/mozilla/mailnews/base/prefs/resources/content/am-main.xul
+++ b/mozilla/mailnews/base/prefs/resources/content/am-main.xul
@@ -79,14 +79,6 @@
-
-
-
-
-
-