| @@ 165-175 (lines=11) @@ | ||
| 162 | /** |
|
| 163 | * @inheritDoc |
|
| 164 | */ |
|
| 165 | public function getPrevious() |
|
| 166 | { |
|
| 167 | $page_number = $this->getCurrent(); |
|
| 168 | if (!$this->isActive()): |
|
| 169 | return null; |
|
| 170 | endif; |
|
| 171 | ||
| 172 | return $page_number > $this->getFirst() |
|
| 173 | ? $page_number - 1 |
|
| 174 | : null; |
|
| 175 | } |
|
| 176 | ||
| 177 | ||
| 178 | ||
| @@ 182-192 (lines=11) @@ | ||
| 179 | /** |
|
| 180 | * @inheritDoc |
|
| 181 | */ |
|
| 182 | public function getNext() |
|
| 183 | { |
|
| 184 | $page_number = $this->getCurrent(); |
|
| 185 | if (!$this->isActive()): |
|
| 186 | return null; |
|
| 187 | endif; |
|
| 188 | ||
| 189 | return $page_number < $this->getLast() |
|
| 190 | ? $page_number + 1 |
|
| 191 | : null; |
|
| 192 | } |
|
| 193 | ||
| 194 | ||
| 195 | ||