diff --git a/mail/components/compose/content/MsgComposeCommands.js b/mail/components/compose/content/MsgComposeCommands.js index 86b2444ebf2..0020d381b12 100644 --- a/mail/components/compose/content/MsgComposeCommands.js +++ b/mail/components/compose/content/MsgComposeCommands.js @@ -22,6 +22,7 @@ # # Contributor(s): # David Bienvenu +# Olivier Parniere BT Global Services / Etat francais Ministere de la Defense # # Alternatively, the contents of this file may be used under the terms of # either the GNU General Public License Version 2 or later (the "GPL"), or @@ -117,6 +118,7 @@ var gCharsetConvertManager; var gLastWindowToHaveFocus; var gReceiptOptionChanged; +var gDSNOptionChanged; var gAttachVCardOptionChanged; var gMailSession; @@ -161,6 +163,7 @@ function InitializeGlobalVariables() gLastWindowToHaveFocus = null; gReceiptOptionChanged = false; + gDSNOptionChanged = false; gAttachVCardOptionChanged = false; } InitializeGlobalVariables(); @@ -1306,6 +1309,7 @@ function ComposeStartup(recycled, aParams) document.getElementById("returnReceiptMenu").setAttribute('checked', gMsgCompose.compFields.returnReceipt); + document.getElementById("dsnMenu").setAttribute('checked', gMsgCompose.compFields.DSN); document.getElementById("cmd_attachVCard").setAttribute('checked', gMsgCompose.compFields.attachVCard); document.getElementById("menu_inlineSpellCheck").setAttribute('checked', sPrefs.getBoolPref("mail.spellcheck.inline")); @@ -2293,6 +2297,17 @@ function ToggleReturnReceipt(target) } } +function ToggleDSN(target) +{ + var msgCompFields = gMsgCompose.compFields; + if (msgCompFields) + { + msgCompFields.DSN = ! msgCompFields.DSN; + target.setAttribute('checked', msgCompFields.DSN); + gDSNOptionChanged = true; + } +} + function ToggleAttachVCard(target) { var msgCompFields = gMsgCompose.compFields; @@ -3015,6 +3030,7 @@ function LoadIdentity(startup) var prevReplyTo = prevIdentity.replyTo; var prevBcc = ""; var prevReceipt = prevIdentity.requestReturnReceipt; + var prevDSN = prevIdentity.DSN; var prevAttachVCard = prevIdentity.attachVCard; if (prevIdentity.doBcc) @@ -3023,6 +3039,7 @@ function LoadIdentity(startup) var newReplyTo = gCurrentIdentity.replyTo; var newBcc = ""; var newReceipt = gCurrentIdentity.requestReturnReceipt; + var newDSN = gCurrentIdentity.DSN; var newAttachVCard = gCurrentIdentity.attachVCard; if (gCurrentIdentity.doBcc) @@ -3039,6 +3056,14 @@ function LoadIdentity(startup) document.getElementById("returnReceiptMenu").setAttribute('checked',msgCompFields.returnReceipt); } + if (!gDSNOptionChanged && + prevDSN == msgCompFields.DSN && + prevDSN != newDSN) + { + msgCompFields.DSN = newDSN; + document.getElementById("dsnMenu").setAttribute('checked',msgCompFields.DSN); + } + if (!gAttachVCardOptionChanged && prevAttachVCard == msgCompFields.attachVCard && prevAttachVCard != newAttachVCard) diff --git a/mail/components/compose/content/messengercompose.xul b/mail/components/compose/content/messengercompose.xul index 38c310d68fd..88e7028ea3f 100644 --- a/mail/components/compose/content/messengercompose.xul +++ b/mail/components/compose/content/messengercompose.xul @@ -24,6 +24,7 @@ # Ben Goodger (ass'td polish fixes) # Hkan Waara # Neil Rashbrook (ass'td polish fix) +# Olivier Parniere BT Global Services / Etat francais Ministere de la Defense # # Alternatively, the contents of this file may be used under the terms of # either the GNU General Public License Version 2 or later (the "GPL"), or @@ -430,6 +431,7 @@ +