kodi
Public Member Functions | List of all members
KODI::GAME::CGUIControllerList Class Reference
Inheritance diagram for KODI::GAME::CGUIControllerList:
Inheritance graph
[legend]
Collaboration diagram for KODI::GAME::CGUIControllerList:
Collaboration graph
[legend]

Public Member Functions

 CGUIControllerList (CGUIWindow *window, IFeatureList *featureList, GameClientPtr gameClient, std::string controllerId)
 Create a GUI controller list. More...
 
bool Initialize () override
 Initialize the resource. More...
 
void Deinitialize () override
 Deinitialize the resource.
 
bool Refresh (const std::string &controllerId) override
 Refresh the contents of the list. More...
 
void OnFocus (unsigned int controllerIndex) override
 
void OnSelect (unsigned int controllerIndex) override
 The specified controller has been selected. More...
 
int GetFocusedController () const override
 Get the index of the focused controller. More...
 
void ResetController () override
 Reset the focused controller. More...
 

Constructor & Destructor Documentation

◆ CGUIControllerList()

CGUIControllerList::CGUIControllerList ( CGUIWindow window,
IFeatureList featureList,
GameClientPtr  gameClient,
std::string  controllerId 
)

Create a GUI controller list.

Parameters
windowThe GUI window handle
featureListThe controller interface for the feature list
gameClientA gameclient used to filter controllers
controllerIdA controller ID used to filter controllers (only the specified controller will be shown, or the default controller if the specified controller isn't installed)

Member Function Documentation

◆ GetFocusedController()

int KODI::GAME::CGUIControllerList::GetFocusedController ( ) const
inlineoverridevirtual

Get the index of the focused controller.

Returns
The index of the focused controller, or -1 if no controller has been focused yet

Implements KODI::GAME::IControllerList.

◆ Initialize()

bool CGUIControllerList::Initialize ( )
overridevirtual

Initialize the resource.

Returns
true if the resource is initialized and can be used false if the resource failed to initialize and must not be used

Implements KODI::GAME::IControllerList.

◆ OnFocus()

void CGUIControllerList::OnFocus ( unsigned int  controllerIndex)
overridevirtual
Todo:
Activate controller for all game controller controls

Implements KODI::GAME::IControllerList.

◆ OnSelect()

void CGUIControllerList::OnSelect ( unsigned int  controllerIndex)
overridevirtual

The specified controller has been selected.

Parameters
controllerIndexThe index of the controller being selected

Implements KODI::GAME::IControllerList.

◆ Refresh()

bool CGUIControllerList::Refresh ( const std::string &  controllerId)
overridevirtual

Refresh the contents of the list.

Parameters
controllerIdThe controller to focus, or empty to leave focus unchanged
Returns
True if the list was changed

Implements KODI::GAME::IControllerList.

◆ ResetController()

void CGUIControllerList::ResetController ( )
overridevirtual

Reset the focused controller.

Todo:
Choose peripheral

Implements KODI::GAME::IControllerList.


The documentation for this class was generated from the following files: