Changeset 848 in subversion
- Timestamp:
- Oct 2, 2007 4:42:18 AM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/roundcubemail/program/steps/mail/move_del.inc
r847 r848 22 22 // count messages before changing anything 23 23 $old_count = $IMAP->messagecount(); 24 $old_pages = ceil($old_count / $IMAP->page_size); 24 25 25 26 // move messages … … 65 66 66 67 67 $remaining = $old_count - $IMAP->page_size * $IMAP->list_page; 68 $msg_count = $IMAP->messagecount(); 69 $pages = ceil($msg_count / $IMAP->page_size); 70 $nextpage_count = $old_count - $IMAP->page_size * $IMAP->list_page; 71 $remaining = $msg_count - $IMAP->page_size * ($IMAP->list_page - 1); 68 72 69 73 // jump back one page (user removed the whole last page) 70 if ($IMAP->list_page > 1 && $ remaining <= 0)74 if ($IMAP->list_page > 1 && $nextpage_count <= 0 && $remaining == 0) 71 75 { 72 76 $IMAP->set_page($IMAP->list_page-1); … … 76 80 77 81 // update message count display 78 $msg_count = $IMAP->messagecount();79 $pages = ceil($msg_count / $IMAP->page_size);80 82 $OUTPUT->set_env('pagecount', $pages); 81 83 $OUTPUT->set_env('current_page', $IMAP->list_page); … … 93 95 94 96 // add new rows from next page (if any) 95 if ($_POST['_from']!='show' && ($jump_back || $ remaining> 0))97 if ($_POST['_from']!='show' && ($jump_back || $nextpage_count > 0)) 96 98 { 97 99 $sort_col = isset($_SESSION['sort_col']) ? $_SESSION['sort_col'] : $CONFIG['message_sort_col'];
Note: See TracChangeset
for help on using the changeset viewer.
