public function getCount()
{
if ($this->_customPaging) {
return parent::getCount();
} else {
if ($this->_currentPageIndex === $this->getPageCount() - 1) {
return parent::getCount() - $this->_pageSize * $this->_currentPageIndex;
} else {
return $this->_pageSize;
}
}
}