From: stekkel Date: Sun, 29 Jun 2003 10:56:05 +0000 (+0000) Subject: removal of status call requests. X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=0654bd86997557a3c8ff10c233caae6a1643cbe8;p=squirrelmail.git removal of status call requests. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@5160 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- diff --git a/src/left_main.php b/src/left_main.php index 7b0ad989..8a572a87 100644 --- a/src/left_main.php +++ b/src/left_main.php @@ -100,10 +100,6 @@ function formatMailboxName($imapConnection, $box_array) { "  ("._("purge").")" . ""; } - } else { - $line .= concat_hook_function('left_main_after_each_folder', - array(isset($numMessages) ? $numMessages : '', - $real_box, $imapConnection)); } /* Return the final product. */ @@ -297,29 +293,24 @@ function listBoxes ($boxes, $j=0 ) { if (isset($boxes) && !empty($boxes)) { $mailbox = $boxes->mailboxname_full; $leader = ''; - $leader .= str_repeat('  ',$j); + $leader .= str_repeat('   ',$j); $mailboxURL = urlencode($mailbox); - /* get unseen/total messages information */ - if ($boxes->unseen||$boxes->total) { + if ($boxes->unseen !== false || $boxes->total !== false) { $unseen = $boxes->unseen; $unseen_string = "($unseen)"; if ($unseen>0||$boxes->total>0) { $unseen_found = TRUE; } - $unseen_before = ''; $unseen_after = ''; - if ((($unseen_notify == 2) && (strtolower($mailbox) == 'inbox')) || ($unseen_notify == 3)) { $unseen_string = '(' . $unseen; - + if ($unseen_type > 1) { $unseen_string .= '/' . $boxes->total; } - $unseen_string .= ')'; - $unseen_string = $unseen_before . $unseen_string . $unseen_after; } } else { @@ -343,25 +334,19 @@ function listBoxes ($boxes, $j=0 ) { } /* If there are unseen message, bold the line. */ - if (($move_to_trash) && ($mailbox == $trash_folder)) { - if (! isset($numMessages)) { - $status = sqimap_status_messages($imapConnection, $mailbox); - $numMessages = $status['MESSAGES']; + if (! isset($boxes->total)) { + $boxes->total = sqimap_status_messages($imapConnection, $mailbox); } - if ($unseen > 0) { $pre .= ''; } - $pre .= ""; - if ($unseen > 0) { $end .= ''; } - $end .= ''; - if ($numMessages > 0) { + if ($boxes->total > 0) { if ($unseen > 0) { $pre .= ''; } @@ -428,12 +413,12 @@ function ListAdvancedBoxes ($boxes, $mbx, $j='ID.0000' ) { $mailboxURL = urlencode($mailbox); /* get unseen/total messages information */ - if ($boxes->unseen) { + if ($boxes->unseen !== false) { $unseen = $boxes->unseen; - $unseen_string = "($unseen)"; + $unseen_string = "($unseen)"; if ($unseen>0) $unseen_found = TRUE; - if ($boxes->total) { - $numMessages = $boxes->total; + if ($boxes->total) { + $numMessages = $boxes->total; $unseen_string = "($unseen/$numMessages)"; } } else $unseen = 0; @@ -987,6 +972,7 @@ for ($i = 0; $i < count($boxes); $i++) { echo ''."\n"; echo ''."\n"; } else { + //sqimap_get_status_mbx_tree($imap_stream,$boxes) ListBoxes($boxes); } } /* if ($oldway) else ... */