Closed Bug 28859 Opened 25 years ago Closed 25 years ago

HTML intelligent send fires upon Save as Draft/Template

Categories

(MailNews Core :: Composition, defect, P3)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: laurel, Assigned: bugzilla)

Details

(Whiteboard: [PDT-])

Using feb 22 builds, all platforms

The HTML Intelligent Send question dialog fires upon saving a message
composition as Draft or Template.  The intelligent send stuff shouldn't surface
until we send the message. 

1.  Edit|Prefs|Mail&newsgroups|Formatting. Enable the first option "Ask me what
to do when message has HTML formatting" (default).
2.  Compose an html message to test9@foobar
3.  From the compose window, File|Save As|Draft.
   
Result:  HTML Intelligent Send dialog displays asking about what format in which
to send the message.

Expected result:  Message should save to draft without asking about format. 
Formatting question should be asked upon sending the message.
QA Contact: lchiang → fenella
Correcting summary
Summary: message → HTML intelligent send fires upon Save as Draft/Template
Accepting. Should be am easy fix.
Status: NEW → ASSIGNED
Whiteboard: [dogfood]
Target Milestone: M14
Moving dogfood to keyword field from Status Summary.
Keywords: dogfood
Whiteboard: [dogfood]
Putting on PDT- radar for dogfood. An annoyance, but will not hold for this.
Whiteboard: [PDT-]
The easy fix is o check is we are sending now or later the message before 
checking for eventual HTML formatting conflict.

Index: MsgComposeCommands.js
===================================================================
RCS file: 
/cvsroot/mozilla/mailnews/compose/resources/content/MsgComposeCommands.js,v
retrieving revision 1.73
diff -r1.73 MsgComposeCommands.js
451,479c451,482
<
<                   // Before sending the message, check what to do with HTML 
message, eventually abort.
<             action = DetermineHTMLAction();
<             if (action == msgCompSendFormat.AskUser)
<             {
<                 var result = {action:msgCompSendFormat.PlainText, 
abort:false};
<                   
window.openDialog("chrome://messengercompose/content/askSendFormat.xul",
<                                       "askSendFormatDialog", "chrome,modal",
<                                       result);
<                   if (result.abort)
<                       return;
<                    action = result.action;
<             }
<             switch (action)
<             {
<                 case msgCompSendFormat.PlainText:
<                     msgCompFields.SetTheForcePlainText(true);
<                     msgCompFields.SetUseMultipartAlternativeFlag(false);
<                     break;
<                 case msgCompSendFormat.HTML:
<                     msgCompFields.SetTheForcePlainText(false);
<                     msgCompFields.SetUseMultipartAlternativeFlag(false);
<                     break;
<                 case msgCompSendFormat.Both:
<                     msgCompFields.SetTheForcePlainText(false);
<                     msgCompFields.SetUseMultipartAlternativeFlag(true);
<                               break;
<                default: dump("\###SendMessage Error: invalid action value\n"); 
return;
<             }
---
>
>                       if (msgType == msgCompDeliverMode.Now || msgType == 
msgCompDeliverMode.Later)
>                       {
>                               // Before sending the message, check what to do 
with HTML message, eventually abort.
>                               action = DetermineHTMLAction();
>                               if (action == msgCompSendFormat.AskUser)
>                               {
>                                       var result = 
{action:msgCompSendFormat.PlainText, abort:false};
>                                       
window.openDialog("chrome://messengercompose/content/askSendFormat.xul",
>                                                                               
"askSendFormatDialog", "chrome,modal",
>                                                                               
result);
>                                       if (result.abort)
>                                               return;
>                                        action = result.action;
>                               }
>                               switch (action)
>                               {
>                                       case msgCompSendFormat.PlainText:
>                                               
msgCompFields.SetTheForcePlainText(true);
>                                               
msgCompFields.SetUseMultipartAlternativeFlag(false);
>                                               break;
>                                       case msgCompSendFormat.HTML:
>                                               
msgCompFields.SetTheForcePlainText(false);
>                                               
msgCompFields.SetUseMultipartAlternativeFlag(false);
>                                               break;
>                                       case msgCompSendFormat.Both:
>                                               
msgCompFields.SetTheForcePlainText(false);
>                                               
msgCompFields.SetUseMultipartAlternativeFlag(true);
>                                               break;
>                                  default: dump("\###SendMessage Error: invalid 
action value\n"); return;
>                               }
>                       }
Whiteboard: [PDT-] → [PDT-]fix in hand
Code reviewed by mscott
Fixed and checked in
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Whiteboard: [PDT-]fix in hand → [PDT-]
Change TM to M15
Target Milestone: M14 → M15
Linux (2000-03-17-08 M15) commercial trunk
MAc (2000-03-17-08 M15) commercial trunk
Win 32 (2000-03-17-09 M15) commercial trunk
This problem is fixed in the trunk builds of all 3 platforms. Need to test it in
the beta 1 build.
Per ducarroz, this is is PDT- bug, so it would not be in the beta1 builds. 
Mark it verified.
Status: RESOLVED → VERIFIED
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.