2016-12-05, 23:12
I did read in Kodi 17, first you have to enable the slider to move itself.
Is it possible to get move the slider left by down and right by up key?
Is it possible to get move the slider left by down and right by up key?
(2016-12-06, 12:16)ronie Wrote: there's no way to override that.
def key_up():
if slider.horizontal.enabled:
key_right()
def key_down():
if slider.horizontal.enabled:
key_left()
def key_left():
if slider.vertical.enabled:
key_down()
def key_right():
if slider.vertical.enabled:
key_up()
bool CGUISliderControl::OnAction(const CAction &action)
{
switch ( action.GetID() )
{
case ACTION_MOVE_LEFT:
if (IsActive() && m_orientation == HORIZONTAL)
{
Move(-1);
return true;
}
if (IsActive() && m_orientation == VERTICAL)
{
Move(-1);
return true;
}
break;
case ACTION_MOVE_RIGHT:
if (IsActive() && m_orientation == HORIZONTAL)
{
Move(1);
return true;
}
if (IsActive() && m_orientation == VERTICAL)
{
Move(1);
return true;
}
break;
case ACTION_MOVE_UP:
if (IsActive() && m_orientation == HORIZONTAL)
{
Move(1);
return true;
}
if (IsActive() && m_orientation == VERTICAL)
{
Move(1);
return true;
}
break;
case ACTION_MOVE_DOWN:
if (IsActive() && m_orientation == HORIZONTAL)
{
Move(-1);
return true;
}
if (IsActive() && m_orientation == VERTICAL)
{
Move(-1);
return true;
}
break;
case ACTION_SELECT_ITEM:
if (m_rangeSelection)
SwitchRangeSelector();
return true;
default:
break;
}
return CGUIControl::OnAction(action);
}
if (IsActive() && m_orientation == HORIZONTAL)
{
Move(-1);
return true;
}
if (IsActive() && m_orientation == VERTICAL)
{
Move(-1);
return true;
}
break;
if (IsActive())
{
Move(-1);
return true;
}
break;