Added C++ versions of the joystick query functions

Change-Id: I4acdb0a54493e633b2a7a9b265c3958a9ba163d1
This commit is contained in:
Brad Miller
2014-12-05 20:13:23 -05:00
parent 66622b43e7
commit b41690b387
4 changed files with 90 additions and 0 deletions

View File

@@ -262,6 +262,37 @@ bool Joystick::GetButton(ButtonType button)
}
}
/**
* Get the number of axis for a joystick
*
* @return the number of axis for the current joystick
*/
int Joystick::GetAxisCount()
{
return m_ds->GetStickAxisCount(m_port);
}
/**
* Get the number of axis for a joystick
*
* @return the number of buttons on the current joystick
*/
int Joystick::GetButtonCount()
{
return m_ds->GetStickButtonCount(m_port);
}
/**
* Get the number of axis for a joystick
*
* @return then umber of POVs for the current joystick
*/
int Joystick::GetPOVCount()
{
return m_ds->GetStickPOVCount(m_port);
}
/**
* Get the channel currently associated with the specified axis.
*