From 97a5e85f4be1d46cbc38e94e999516d844618805 Mon Sep 17 00:00:00 2001 From: jangliss Date: Thu, 17 Jul 2003 06:32:50 +0000 Subject: [PATCH] Should have checked in further details what the possible side effects could be... for now just mark them as Special Folders. That should take care of it. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@5328 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/imap_mailbox.php | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/functions/imap_mailbox.php b/functions/imap_mailbox.php index 892c0f56..df4147b0 100755 --- a/functions/imap_mailbox.php +++ b/functions/imap_mailbox.php @@ -831,11 +831,22 @@ function sqimap_fill_mailbox_tree($mbx_ary, $mbxs=false,$imap_stream) { $mbx = new mailboxes(); $mailbox = $mbx_ary[$i]['mbx']; - /* @@@ FIXME @@@ + /* sent subfolders messes up using existing code as subfolders were marked, but the parents were ordered somewhere else in the list, despite having "special folders at top" option set. Need a better method than this. + */ + + if ($mailbox == 'INBOX') { + $mbx->is_special = true; + } elseif (stristr($trash_folder , $mailbox)) { + $mbx->is_special = true; + } elseif (stristr($sent_folder , $mailbox)) { + $mbx->is_special = true; + } elseif (stristr($draft_folder , $mailbox)) { + $mbx->is_special = true; + } switch ($mailbox) { case 'INBOX': @@ -856,8 +867,6 @@ function sqimap_fill_mailbox_tree($mbx_ary, $mbxs=false,$imap_stream) { break; } - /FIXME/ - */ if ($mailbox == 'INBOX') { $mbx->is_inbox = true; -- 2.25.1