From a862043fe7d6095de0af7425ae5b2485bb896eb2 Mon Sep 17 00:00:00 2001
From: svncommit <devs@roundcube.net>
Date: Sat, 04 Oct 2008 23:05:16 -0400
Subject: [PATCH] restore some script environment variables removed in r1918 but needed in "show" action

---
 program/steps/mail/func.inc |   11 ++++++++++-
 1 files changed, 10 insertions(+), 1 deletions(-)

diff --git a/program/steps/mail/func.inc b/program/steps/mail/func.inc
index f2c4ea4..b7ef82c 100644
--- a/program/steps/mail/func.inc
+++ b/program/steps/mail/func.inc
@@ -73,6 +73,15 @@
 
   $OUTPUT->set_pagetitle(rcmail_localize_foldername($IMAP->get_mailbox_name()));
   }
+else if ($RCMAIL->action == 'show')
+  {
+  // set current mailbox in client environment
+  $OUTPUT->set_env('mailbox', $IMAP->get_mailbox_name());
+  if ($CONFIG['trash_mbox'])
+    $OUTPUT->set_env('trash_mailbox', $CONFIG['trash_mbox']);
+  if (!$OUTPUT->ajax_call)
+    rcube_add_label('checkingmail', 'deletemessage', 'movemessagetotrash', 'movingmessage');
+  }
 
 
 /**
@@ -183,7 +192,7 @@
     $out .= '<td class="'.$col.$sort_class.'" id="rcmHead'.$col.'">' . "$col_name$sort</td>\n";    
     }
 
-  $out .= '<td class="icon">'.($attrib['attachmenticon'] ? sprintf($image_tag, $skin_path, $attrib['attachmenticon'], '') : '')."</td>\n";
+  $out .= '<td class="icon">'.($attrib['attachmenticon'] ? sprintf($image_tag, $skin_path, $attrib['attachmenticon'], '') : '&nbsp;')."</td>\n";
   $out .= "</tr></thead>\n<tbody>\n";
 
   // no messages in this mailbox

--
Gitblit v1.9.1