rem:   var attachmentView = attachmentList.appendItem(attachment.displayName); 
add:  var displayName = createAttachmentDisplayName(attachment); var attachmentView = attachmentList.appendItem(displayName);  
context: function displayAttachmentsForExpandedView(){  var numAttachments = currentAttachments.length;   var expandedAttachmentBox = document.getElementById('attachmentView');  var attachmentSplitter = document.getElementById('attachment-splitter');  if (numAttachments <= 0)  {    expandedAttachmentBox.collapsed = true;    attachmentSplitter.collapsed = true;  }  else if (!gBuildAttachmentsForCurrentMsg)  {    // IMPORTANT: make sure we uncollapse the attachment box BEFORE we start adding    // our attachments to the view. Otherwise, layout doesn't calculate the correct height for    // the attachment view and we end up with a box that is too tall.    expandedAttachmentBox.collapsed = false;    attachmentSplitter.collapsed = false;        if (gShowLargeAttachmentView)      expandedAttachmentBox.setAttribute("largeView", "true");    // Remove height attribute, or the attachments box could be drawn badly:    expandedAttachmentBox.removeAttribute("height");    var attachmentList = document.getElementById('attachmentList');    for (index in currentAttachments)    {      var attachment = currentAttachments[index];      // create a new attachment widget. set the label, set the       // moz-icon img src      var attachmentView = attachmentList.appendItem(attachment.displayName);      attachmentView.setAttribute("class", "descriptionitem-iconic");       if (gShowLargeAttachmentView)        attachmentView.setAttribute("largeView", "true");      setApplicationIconForAttachment(attachment, attachmentView, gShowLargeAttachmentView);      attachmentView.setAttribute("tooltiptext", attachment.displayName);      attachmentView.setAttribute("context", "attachmentListContext");            attachmentView.attachment = cloneAttachment(attachment);      attachmentView.setAttribute("attachmentUrl", attachment.url);      attachmentView.setAttribute("attachmentContentType", attachment.contentType);      attachmentView.setAttribute("attachmentUri", attachment.uri);      var item = attachmentList.appendChild(attachmentView);    } // for each attachment    gBuildAttachmentsForCurrentMsg = true;    // Switch overflow off (via css attribute selector) temporarily to get the preferred window height:    var attachmentContainer = document.getElementById('attachmentView');    attachmentContainer.setAttribute("attachmentOverflow", "false");    var attachmentHeight = expandedAttachmentBox.boxObject.height;    attachmentContainer.setAttribute("attachmentOverflow", "true");    // If the attachments box takes up too much of the message pane, downsize:    var maxAttachmentHeight = document.getElementById('messagepanebox').boxObject.height / 4;    if (attachmentHeight > maxAttachmentHeight)      attachmentHeight = maxAttachmentHeight;    expandedAttachmentBox.setAttribute("height", attachmentHeight); }}
meta: 9421	/local1/tlutelli/issta_data/temp/all_js/javascript/2007_temp/2007/9421/f7560cc3b32c24ba0961db0449c393bb0b364266/msgHdrViewOverlay.js/clean/mail/base/content/msgHdrViewOverlay.js