channellist, bouquetlist and bouqueteditor: fix pagedown logic

Origin commit data
------------------
Branch: ni/coolstream
Commit: ed4adff745
Author: vanhofen <vanhofen@gmx.de>
Date: 2015-11-08 (Sun, 08 Nov 2015)

Origin message was:
------------------
- channellist, bouquetlist and bouqueteditor: fix pagedown logic

------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
vanhofen
2015-11-08 19:30:59 +01:00
parent 28d0e563a1
commit 849e936082
4 changed files with 4 additions and 4 deletions

View File

@@ -748,7 +748,7 @@ int CChannelList::show()
int step = ((int) msg == g_settings.key_pagedown) ? listmaxshow : 1; // browse or step 1
int new_selected = selected + step;
if (new_selected >= (int) (*chanlist).size()) {
if (((*chanlist).size() - listmaxshow -1 < selected) && (selected != ((*chanlist).size() - 1)) && (step != 1))
if ((((*chanlist).size() - listmaxshow -1 < selected) && (step != 1)) || (selected != ((*chanlist).size() - 1)))
new_selected = (*chanlist).size() - 1;
else if ((((*chanlist).size() / listmaxshow) + 1) * listmaxshow == (*chanlist).size() + listmaxshow) // last page has full entries
new_selected = 0;