Closed Bug 144296 Opened 23 years ago Closed 22 years ago

MDN: return receipts not on for different ways to bring up compose window

Categories

(SeaMonkey :: MailNews: Backend, defect)

x86
All
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED
mozilla1.4alpha

People

(Reporter: grylchan, Assigned: cavin)

References

Details

(Whiteboard: [adt2 rtm],custrtm-)

Attachments

(1 file, 2 obsolete files)

I'm using 2002-05-12-20-XX-PR1 on windows nt 4.0 but I'm sure this applies to trunk,branch, and all os's. If you have 'when sending a message always request a return receipt' on and you compose a mesg any of these ways: -click on mail to link -click on a mail header url -from browser: file|Send page or file|send link -select a address in your address book and click the compose button on the address book -address book: file|new mesg There will be no request for a return receipt tied to that message. It's not using the user's identity. It does work for the following: -browser, messenger, or composer: file|New mesg, see bug 134280 -using compose button in messenger Steps to reproduce: 1.Go to return receipt prefs and check 'when sending a message always request a return receipt' 2.Compose a mesg by any of the ways listed above result: go to compose window and select from menu: Options|Return Receipt Notice it's not checked. If you send the mesg it will not prompt the addressee for a return receipt expected: to have return receipt on for any way to compose a mesg
Keywords: nsbeta1
Jeff any ideas on how to fix this?
Keywords: nsbeta1nsbeta1+
Whiteboard: [adt2 rtm]
Whiteboard: [adt2 rtm] → [adt2 rtm],custrtm-
adding 'edit as new' as another test case where this doesnt work properly.
*** Bug 156914 has been marked as a duplicate of this bug. ***
Reassigning.
Assignee: jt95070 → cavin
Attached patch Proposed patch, v1 (obsolete) — Splinter Review
Set/Init return receipt flag in nsMsgCompose::Initialize().
Attachment #114144 - Flags: superreview?(sspitzer)
Summary: mdn:return receipts not on for different ways to bring up compose window → MDN: return receipts not on for different ways to bring up compose window
Comment on attachment 114144 [details] [diff] [review] Proposed patch, v1 this is similar to, but not exactly the same code as in nsMsgComposeService::OpenComposeWindow() PRBool requestReturnReceipt = PR_FALSE; PRInt32 receiptType = nsIMsgMdnGenerator::eDntType; if (identity) { identity->GetRequestReturnReceipt(&requestReturnReceipt); identity->GetReceiptHeaderType(&type); } pMsgCompFields->SetReturnReceipt(requestReturnReceipt); pMsgCompFields->SetReceiptHeaderType(receiptType); I think want to set call Get/SetReceiptHeaderType() too. also, these four calls return rv, but your patch (and the code in OpenComposeWindow()) doesn't check. I think we should add checks. I don't think they should ever fail, but can you double check? if they shouldn't fail, we should fix your patch (and the code in OpenComposeWindow()) to do: rv = GetFoo(); // SetFoo(); NS_ENSURE_SUCCESS(rv, rv);
Attachment #114144 - Flags: superreview?(sspitzer) → superreview-
I think they way you've done this will make it work properly for the cached compose window, but please make sure. for more info on that, see http://www.mozilla.org/mailnews/arch/compose/cached.html
Attached patch Proposed patch, v2 (obsolete) — Splinter Review
Looks like we don't have to set the flag and type in nsMsgComposeService::OpenComposeWindow() because nsMsgCompose::Initialize() is always called (by nsMsgComposeService::InitCompose()) in all cases I tested unless I missed something. Cached compose window works fine with the patch as well.
Attachment #114144 - Attachment is obsolete: true
Attachment #114290 - Flags: superreview?(sspitzer)
looks good. two minor nits. fix them, and then r/sr=sspitzer 1) is it possible for m_identity to be null in nsMsgCompose::Initialize()? (I'm not sure if nsMsgComposeService::OpenWindow() is always called first, which will set the identity to the default identity if not set) the reason I ask is one difference between your patch and the code you removed in nsMsgComposeService::OpenComposeWindow() is that in the existing code, if we don't have an identity, we still call SetReturnReceipt() and SetReceiptHeaderType() I looked into it, and I think it would be ok not call them if the default values for m_returnReceipt and m_receiptHeaderType were correct. m_returnReceipt is, but m_receiptHeaderType is not. receiptHeaderType is uninitialized! can you initialize it in nsMsgCompFields::nsMsgCompFields() to be nsIMsgMdnGenerator::eDntType? 2) I think you can now remove #include "nsIMsgMdnGenerator.h" from nsMsgComposeService.cpp, since it is no longer used.
Comment on attachment 114290 [details] [diff] [review] Proposed patch, v2 minusing, to clear my request queue. when you have a final patch, I'll give you that quick r/sr
Attachment #114290 - Flags: superreview?(sspitzer) → superreview-
> can you initialize it in nsMsgCompFields::nsMsgCompFields() to be > nsIMsgMdnGenerator::eDntType? > Excellent catch. Thanks. I'll remove: #include "nsIMsgMdnGenerator.h" from nsMsgComposeService.cpp.
Incorporated comments.
Attachment #114290 - Attachment is obsolete: true
Attachment #114309 - Flags: superreview?(sspitzer)
Comment on attachment 114309 [details] [diff] [review] Proposed patch, v3. r/sr=sspitzer nice work, cavin.
Attachment #114309 - Flags: superreview?(sspitzer)
Attachment #114309 - Flags: superreview+
Attachment #114309 - Flags: review+
Target Milestone: --- → mozilla1.4alpha
Fix checked in.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
this caused a regression, see bug #195364 (but I think it's just that a default pref is missing)
actually, it was something else (but equally as small) see bug #195364 for details.
the problem was with the implementation (not cavin's) of nsMsgIdentity::GetReceiptHeaderTypeGetReceiptHeaderType() cavin must have per-account overrides turned on, which is why he didn't see it.
but this did cause a regression. see bug #195367 (reply not quoting) here's the fix - rv = m_identity->GetReceiptHeaderType(&type); + rv = m_identity->GetReceiptHeaderType(&receiptType);
Trunk build 2003-03-05: Mac 10.1.5 Trunk build 2003-03-05: WinXP Verified Fixed. The following scenarios result in a return receipt appearing. -click on mail to link -click on a mail header url -from browser: - file|Send page or - file|send link -from address book: - click the compose button with a card selected - file|new mesg with a card selected
Status: RESOLVED → VERIFIED
Product: Browser → Seamonkey
Component: MailNews: Return Receipts → MailNews: Backend
QA Contact: grylchan → offline
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: