Skip to content

Commit

Permalink
[pvr] Fix list change with first or last page selection on Channel Ma…
Browse files Browse the repository at this point in the history
…nager
  • Loading branch information
AlwinEsch committed Feb 7, 2015
1 parent 18e4a08 commit ccfd912
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions xbmc/pvr/dialogs/GUIDialogPVRChannelManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,8 @@ bool CGUIDialogPVRChannelManager::OnActionMove(const CAction &action)
}

if (iActionId == ACTION_MOVE_DOWN || iActionId == ACTION_MOVE_UP ||
iActionId == ACTION_PAGE_DOWN || iActionId == ACTION_PAGE_UP)
iActionId == ACTION_PAGE_DOWN || iActionId == ACTION_PAGE_UP ||
iActionId == ACTION_FIRST_PAGE || iActionId == ACTION_LAST_PAGE)
{
CGUIDialog::OnAction(action);
int iSelected = m_viewControl.GetSelectedItem();
Expand All @@ -114,7 +115,7 @@ bool CGUIDialogPVRChannelManager::OnActionMove(const CAction &action)
{
std::string strNumber;

bool bMoveUp = iActionId == ACTION_PAGE_UP || iActionId == ACTION_MOVE_UP;
bool bMoveUp = iActionId == ACTION_PAGE_UP || iActionId == ACTION_MOVE_UP || iActionId == ACTION_FIRST_PAGE;
unsigned int iLines = bMoveUp ? abs(m_iSelected - iSelected) : 1;
bool bOutOfBounds = bMoveUp ? m_iSelected <= 0 : m_iSelected >= m_channelItems->Size() - 1;
if (bOutOfBounds)
Expand Down

0 comments on commit ccfd912

Please sign in to comment.