mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-28 16:01:20 +02:00
-use right/left pagedown/pageup in timerlist
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@1209 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
@@ -501,7 +501,7 @@ int CTimerList::show()
|
||||
}
|
||||
}
|
||||
else if ( ( msg == CRCInput::RC_timeout ) ||
|
||||
( msg == CRCInput::RC_home) )
|
||||
( msg == CRCInput::RC_home) || (msg == CRCInput::RC_left) )
|
||||
{ //Exit after timeout or cancel key
|
||||
if ( fadeIn ) {
|
||||
g_RCInput->killTimer(fadeTimer);
|
||||
@@ -516,16 +516,17 @@ int CTimerList::show()
|
||||
} else
|
||||
loop=false;
|
||||
}
|
||||
else if ((msg == CRCInput::RC_up) && !(timerlist.empty()))
|
||||
{
|
||||
int prevselected=selected;
|
||||
if (selected==0)
|
||||
else if ((msg == CRCInput::RC_up || msg == (unsigned int)g_settings.key_channelList_pageup) && !(timerlist.empty()))
|
||||
{
|
||||
int step = 0;
|
||||
int prev_selected = selected;
|
||||
|
||||
step = (msg == (unsigned int)g_settings.key_channelList_pageup) ? listmaxshow : 1; // browse or step 1
|
||||
selected -= step;
|
||||
if((prev_selected-step) < 0) // because of uint
|
||||
selected = timerlist.size() - 1;
|
||||
}
|
||||
else
|
||||
selected--;
|
||||
paintItem(prevselected - liststart);
|
||||
|
||||
paintItem(prev_selected - liststart);
|
||||
unsigned int oldliststart = liststart;
|
||||
liststart = (selected/listmaxshow)*listmaxshow;
|
||||
if (oldliststart!=liststart)
|
||||
@@ -537,11 +538,23 @@ int CTimerList::show()
|
||||
paintItem(selected - liststart);
|
||||
}
|
||||
}
|
||||
else if ((msg == CRCInput::RC_down) && !(timerlist.empty()))
|
||||
else if ((msg == CRCInput::RC_down || msg == (unsigned int)g_settings.key_channelList_pagedown) && !(timerlist.empty()))
|
||||
{
|
||||
int prevselected=selected;
|
||||
selected = (selected+1)%timerlist.size();
|
||||
paintItem(prevselected - liststart);
|
||||
unsigned int step = 0;
|
||||
int prev_selected = selected;
|
||||
|
||||
step = (msg == (unsigned int)g_settings.key_channelList_pagedown) ? listmaxshow : 1; // browse or step 1
|
||||
selected += step;
|
||||
|
||||
if(selected >= timerlist.size())
|
||||
{
|
||||
if (((timerlist.size() / listmaxshow) + 1) * listmaxshow == timerlist.size() + listmaxshow) // last page has full entries
|
||||
selected = 0;
|
||||
else
|
||||
selected = ((step == listmaxshow) && (selected < (((timerlist.size() / listmaxshow) + 1) * listmaxshow))) ? (timerlist.size() - 1) : 0;
|
||||
}
|
||||
paintItem(prev_selected - liststart);
|
||||
|
||||
unsigned int oldliststart = liststart;
|
||||
liststart = (selected/listmaxshow)*listmaxshow;
|
||||
if (oldliststart!=liststart)
|
||||
@@ -553,7 +566,7 @@ int CTimerList::show()
|
||||
paintItem(selected - liststart);
|
||||
}
|
||||
}
|
||||
else if ((msg == CRCInput::RC_ok) && !(timerlist.empty()))
|
||||
else if ((msg == CRCInput::RC_right || msg == CRCInput::RC_ok) && !(timerlist.empty()))
|
||||
{
|
||||
if (modifyTimer()==menu_return::RETURN_EXIT_ALL)
|
||||
{
|
||||
|
Reference in New Issue
Block a user