From 79f7a8a6cfb2f60154639b055a47a4ea9b89459a Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Thu, 29 May 2014 15:33:27 +0000 Subject: [PATCH] Use popup mail compose window if default document is an email, same as non-default documents --- etemplate/inc/class.bo_merge.inc.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/etemplate/inc/class.bo_merge.inc.php b/etemplate/inc/class.bo_merge.inc.php index 8f849f0ab3..c9f31a197e 100644 --- a/etemplate/inc/class.bo_merge.inc.php +++ b/etemplate/inc/class.bo_merge.inc.php @@ -1664,12 +1664,20 @@ abstract class bo_merge if ($export_limit == null) $export_limit = self::getExportLimit(); // check if there is a globalsetting if ($default_doc && ($file = egw_vfs::stat($default_doc))) // put default document on top { + if(!$file['mime']) + { + $file['mime'] = egw_vfs::mime_content_type($default_doc); + } $documents['document'] = array( 'icon' => egw_vfs::mime_icon($file['mime']), 'caption' => egw_vfs::decodePath(egw_vfs::basename($default_doc)), 'group' => 1, 'postSubmit' => true, // download needs post submit (not Ajax) to work ); + if ($file['mime'] == 'message/rfc822') + { + self::document_mail_action($documents['document'], $file); + } } $files = array();