'html_image_replacement', 'html_image_addrbook',
'highlight_text', 'highlight_simple_markup',
'show_quoteblocks', 'dim_signature', 'emoticons',
- 'parts_display', 'mail_hdr', 'default_msg_charset')
+ 'parts_display', 'atc_display', 'mail_hdr',
+ 'default_msg_charset')
);
if (!empty($GLOBALS['conf']['maillog']['use_maillog'])) {
$prefGroups['viewing']['members'] = array_merge($prefGroups['viewing']['members'], array('disposition_send_mdn'));
),
'desc' => _("Which message parts do you want to display in the summary?"));
+// Should attachment summaries be displayed inline?
+$_prefs['atc_display'] = array(
+ 'value' => 1,
+ 'locked' => false,
+ 'shared' => false,
+ 'type' => 'checkbox',
+ 'desc' => _("Display attachment summary information within the message text?"));
+
// Display custom headers (configured via the identity screen) when viewing
// messages?
$_prefs['mail_hdr'] = array(
continue;
}
+
if (!($render_mode = $imp_contents->canDisplay($mime_id, IMP_Contents::RENDER_INLINE | IMP_Contents::RENDER_INFO))) {
- if (($show_parts == 'atc') &&
- $imp_contents->isAttachment($mime_type)) {
- $atc_parts[] = $mime_id;
+ if ($imp_contents->isAttachment($mime_type)) {
+ if ($show_parts == 'atc') {
+ $atc_parts[] = $mime_id;
+ }
+
+ if ($GLOBALS['prefs']->getValue('atc_display')) {
+ $result['msgtext'] .= $imp_ui->formatSummary($imp_contents->getSummary($mime_id, $contents_mask), $part_info_display);
+ }
}
continue;
}
}
if (!($render_mode = $imp_contents->canDisplay($mime_id, IMP_Contents::RENDER_INLINE | IMP_Contents::RENDER_INFO))) {
- if (($show_parts == 'atc') && $imp_contents->isAttachment($mime_type)) {
- $atc_parts[] = $mime_id;
+ if ($imp_contents->isAttachment($mime_type)) {
+ if ($show_parts == 'atc') {
+ $atc_parts[] = $mime_id;
+ }
+
+ if ($prefs->getValue('atc_display')) {
+ $msgtext .= $imp_ui->formatSummary($imp_contents->getSummary($mime_id, $contents_mask), $part_info_display);
+ }
}
continue;
}