// display changing on the awt event thread. seem simple enough?
// assume that we're actually on the FolderThread for now.
if (getMessageProxy() != null) {
MessageInfo msgInfo = getMessageProxy().getMessageInfo();
StringBuffer messageText = new StringBuffer();
String content = null;
String contentType = "text/plain";
boolean displayHtml = false;
int msgDisplayMode = getMessageProxy().getDisplayMode();
// figure out html vs. text
if (Pooka.getProperty("Pooka.displayHtml", "").equalsIgnoreCase("true")) {
if (msgInfo.isHtml()) {
if (msgDisplayMode > MessageProxy.TEXT_ONLY)
displayHtml = true;
} else if (msgInfo.containsHtml()) {
if (msgDisplayMode >= MessageProxy.HTML_PREFERRED)
displayHtml = true;
} else {
// if we don't have any html, just display as text.
}
}
//Original was true, changed to false by Liao
boolean includeHeaders = false;
boolean showFullheaders = showFullHeaders();
// Get the header Information
String header;
if(showFullheaders){
header = getFullHeaderInfo(msgInfo);
} else {
String list = Pooka.getProperty("MessageWindow.Header.DefaultHeaders", "From:To:CC:Date:Subject");
header = getHeaderInfo(msgInfo, list);
}
headerPane.setText(header);
headerPane.repaint();
// set the content
if (msgDisplayMode == MessageProxy.RFC_822) {
content = msgInfo.getRawText();
} else {
if (displayHtml) {
contentType = "text/html";
if (Pooka.getProperty("Pooka.displayTextAttachments", "").equalsIgnoreCase("true")) {
content = msgInfo.getHtmlAndTextInlines(includeHeaders, showFullheaders);
} else {
content = msgInfo.getHtmlPart(includeHeaders, showFullheaders);
}
} else {
if (Pooka.getProperty("Pooka.displayTextAttachments", "").equalsIgnoreCase("true")) {
// Is there only an HTML part? Regardless, we've determined that
// we will still display it as text.
if (getMessageProxy().getMessageInfo().isHtml())
content = msgInfo.getHtmlAndTextInlines(includeHeaders, showFullheaders);
else
content = msgInfo.getTextAndTextInlines(includeHeaders, showFullheaders);
}
else {
// Is there only an HTML part? Regardless, we've determined that
// we will still display it as text.
if (getMessageProxy().getMessageInfo().isHtml())
content = msgInfo.getHtmlPart(includeHeaders, showFullheaders);
else
content = msgInfo.getTextPart(includeHeaders, showFullheaders);
}
}
}
if (content != null)