Bug #65472 --> Port a thunderbird change back to mozilla mail. If the user has turned on the pref for showing the user-agent string,

show x-mailer if there is no user-agent. We currently show it under the same user-agent box we currently use in the UI.

r/sr=bienvenu
This commit is contained in:
scott%scott-macgregor.org 2003-07-21 05:00:09 +00:00
parent 30614ad556
commit d1c1d95ec2
2 changed files with 7 additions and 1 deletions

View File

@ -308,6 +308,11 @@ var messageHeaderSink = {
// for consistancy sake, let's force all header names to be lower case so
// we don't have to worry about looking for: Cc and CC, etc.
var lowerCaseHeaderName = headerNames[index].toLowerCase();
// if we have an x-mailer string, put it in the user-agent slot which we know how to handle
// already.
if (lowerCaseHeaderName == "x-mailer")
lowerCaseHeaderName = "user-agent";
var foo = new Object;
foo.headerValue = headerValues[index];

View File

@ -227,7 +227,8 @@ NS_IMETHODIMP nsMimeHtmlDisplayEmitter::WriteHTMLHeaders()
nsCRT::strcasecmp("cc", headerInfo->name) && nsCRT::strcasecmp("newsgroups", headerInfo->name) &&
nsCRT::strcasecmp("bcc", headerInfo->name) && nsCRT::strcasecmp("followup-to", headerInfo->name) &&
nsCRT::strcasecmp("reply-to", headerInfo->name) && nsCRT::strcasecmp("subject", headerInfo->name) &&
nsCRT::strcasecmp("organization", headerInfo->name) && nsCRT::strcasecmp("user-agent", headerInfo->name))
nsCRT::strcasecmp("organization", headerInfo->name) && nsCRT::strcasecmp("user-agent", headerInfo->name) &&
nsCRT::strcasecmp("x-mailer", headerInfo->name))
continue;
}