import v2.0.0.0_RC3 | 2012-07-01

https://github.com/lucanos/CommunityID -> http://www.itadmins.net/archives/357
This commit is contained in:
2019-07-17 22:31:04 +02:00
parent 38c146901c
commit 2f397f01f7
2677 changed files with 296182 additions and 45159 deletions

View File

@ -16,7 +16,7 @@
* @package Zend_Paginator
* @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
* @version $Id: Sliding.php 16215 2009-06-21 19:36:07Z thomas $
* @version $Id: Sliding.php 18951 2009-11-12 16:26:19Z alexander $
*/
/**
@ -25,9 +25,9 @@
require_once 'Zend/Paginator/ScrollingStyle/Interface.php';
/**
* A Yahoo! Search-like scrolling style. The cursor will advance to
* the middle of the range, then remain there until the user reaches
* the end of the page set, at which point it will continue on to
* A Yahoo! Search-like scrolling style. The cursor will advance to
* the middle of the range, then remain there until the user reaches
* the end of the page set, at which point it will continue on to
* the end of the range and the last page in the set.
*
* @link http://search.yahoo.com/search?p=Zend+Framework
@ -40,7 +40,7 @@ class Zend_Paginator_ScrollingStyle_Sliding implements Zend_Paginator_ScrollingS
{
/**
* Returns an array of "local" pages given a page number and range.
*
*
* @param Zend_Paginator $paginator
* @param integer $pageRange (Optional) Page range
* @return array
@ -53,23 +53,23 @@ class Zend_Paginator_ScrollingStyle_Sliding implements Zend_Paginator_ScrollingS
$pageNumber = $paginator->getCurrentPageNumber();
$pageCount = count($paginator);
if ($pageRange > $pageCount) {
$pageRange = $pageCount;
}
$delta = ceil($pageRange / 2);
if ($pageNumber - $delta > $pageCount - $pageRange) {
$lowerBound = $pageCount - $pageRange + 1;
$upperBound = $pageCount;
$upperBound = $pageCount;
} else {
if ($pageNumber - $delta < 0) {
$delta = $pageNumber;
}
$offset = $pageNumber - $delta;
$lowerBound = $offset + 1;
$lowerBound = $offset + 1;
$upperBound = $offset + $pageRange;
}