@ -1775,8 +1775,12 @@ TQString KMReaderWin::writeMessagePartToTempFile( KMMessagePart* aMsgPart,
int slashPos = fileName . findRev ( ' / ' ) ;
int slashPos = fileName . findRev ( ' / ' ) ;
if ( - 1 ! = slashPos )
if ( - 1 ! = slashPos )
fileName = fileName . mid ( slashPos + 1 ) ;
fileName = fileName . mid ( slashPos + 1 ) ;
if ( fileName . isEmpty ( ) )
if ( fileName . isEmpty ( ) ) {
fileName = " unnamed " ;
fileName = " unnamed " ;
// Save html emails with extension
if ( aMsgPart - > subtype ( ) = = DwMime : : kSubtypeHtml )
fileName + = " .html " ;
}
fname + = " / " + fileName ;
fname + = " / " + fileName ;
TQByteArray data = aMsgPart - > bodyDecodedBinary ( ) ;
TQByteArray data = aMsgPart - > bodyDecodedBinary ( ) ;
@ -3041,11 +3045,11 @@ TQString KMReaderWin::renderAttachments(partNode * node, const TQColor &bgColor
html + = " </div> " ;
html + = " </div> " ;
}
}
} else {
} else {
TQString fileName = writeMessagePartToTempFile ( & node - > msgPart ( ) , node - > nodeId ( ) ) ;
partNode : : AttachmentDisplayInfo info = node - > attachmentDisplayInfo ( ) ;
partNode : : AttachmentDisplayInfo info = node - > attachmentDisplayInfo ( ) ;
if ( info . displayInHeader ) {
if ( info . displayInHeader ) {
html + = " <div style= \" float:left; \" > " ;
html + = " <div style= \" float:left; \" > " ;
html + = TQString : : fromLatin1 ( " <span style= \" white-space:nowrap; border-width: 0px; border-left-width: 5px; border-color: %1; 2px; border-left-style: solid; \" > " ) . arg ( bgColor . name ( ) ) ;
html + = TQString : : fromLatin1 ( " <span style= \" white-space:nowrap; border-width: 0px; border-left-width: 5px; border-color: %1; 2px; border-left-style: solid; \" > " ) . arg ( bgColor . name ( ) ) ;
TQString fileName = writeMessagePartToTempFile ( & node - > msgPart ( ) , node - > nodeId ( ) ) ;
TQString href = node - > asHREF ( " header " ) ;
TQString href = node - > asHREF ( " header " ) ;
html + = TQString : : fromLatin1 ( " <a href= \" " ) + href +
html + = TQString : : fromLatin1 ( " <a href= \" " ) + href +
TQString : : fromLatin1 ( " \" > " ) ;
TQString : : fromLatin1 ( " \" > " ) ;