|
|
@ -1195,7 +1195,7 @@ function rcmail_mailbox_list($attrib)
|
|
|
|
|
|
|
|
|
|
|
|
// add no-selection option
|
|
|
|
// add no-selection option
|
|
|
|
if ($attrib['noselection'])
|
|
|
|
if ($attrib['noselection'])
|
|
|
|
$select->add(rcube_label($attrib['noselection']), '0');
|
|
|
|
$select->add(rcube_label($attrib['noselection']), '');
|
|
|
|
|
|
|
|
|
|
|
|
rcmail_render_folder_tree_select($hook['list'], $mbox_name, $attrib['maxlength'], $select, $attrib['realnames']);
|
|
|
|
rcmail_render_folder_tree_select($hook['list'], $mbox_name, $attrib['maxlength'], $select, $attrib['realnames']);
|
|
|
|
$out = $select->show();
|
|
|
|
$out = $select->show();
|
|
|
@ -1421,14 +1421,12 @@ function rcmail_render_folder_tree_html(&$arrFolders, &$mbox_name, &$jslist, $at
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
function rcmail_render_folder_tree_select(&$arrFolders, &$mbox_name, $maxlength, &$select, $realnames=false, $nestLevel=0)
|
|
|
|
function rcmail_render_folder_tree_select(&$arrFolders, &$mbox_name, $maxlength, &$select, $realnames=false, $nestLevel=0)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
$idx = 0;
|
|
|
|
|
|
|
|
$out = '';
|
|
|
|
$out = '';
|
|
|
|
foreach ($arrFolders as $key=>$folder)
|
|
|
|
|
|
|
|
{
|
|
|
|
foreach ($arrFolders as $key=>$folder) {
|
|
|
|
if (!$realnames && ($folder_class = rcmail_folder_classname($folder['id'])))
|
|
|
|
if (!$realnames && ($folder_class = rcmail_folder_classname($folder['id'])))
|
|
|
|
$foldername = rcube_label($folder_class);
|
|
|
|
$foldername = rcube_label($folder_class);
|
|
|
|
else
|
|
|
|
else {
|
|
|
|
{
|
|
|
|
|
|
|
|
$foldername = $folder['name'];
|
|
|
|
$foldername = $folder['name'];
|
|
|
|
|
|
|
|
|
|
|
|
// shorten the folder name to a given length
|
|
|
|
// shorten the folder name to a given length
|
|
|
@ -1440,8 +1438,6 @@ function rcmail_render_folder_tree_select(&$arrFolders, &$mbox_name, $maxlength,
|
|
|
|
|
|
|
|
|
|
|
|
if (!empty($folder['folders']))
|
|
|
|
if (!empty($folder['folders']))
|
|
|
|
$out .= rcmail_render_folder_tree_select($folder['folders'], $mbox_name, $maxlength, $select, $realnames, $nestLevel+1);
|
|
|
|
$out .= rcmail_render_folder_tree_select($folder['folders'], $mbox_name, $maxlength, $select, $realnames, $nestLevel+1);
|
|
|
|
|
|
|
|
|
|
|
|
$idx++;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
return $out;
|
|
|
|
return $out;
|
|
|
|