Kodi Documentation 18.0
Kodi is an open source media player and entertainment hub.
IWindowKeymap Class Referenceabstract

Interface for mapping buttons to Kodi actions for specific windows. More...

#include <IKeymap.h>

Inheritance diagram for IWindowKeymap:
CWindowKeymap

Public Member Functions

virtual ~IWindowKeymap ()=default
 
virtual std::string ControllerID () const =0
 The controller ID. More...
 
virtual void MapAction (int windowId, const std::string &keyName, KODI::JOYSTICK::KeymapAction action)=0
 Add an action to the keymap for a given key name and window ID. More...
 
virtual const KODI::JOYSTICK::KeymapActionGroupGetActions (int windowId, const std::string &keyName) const =0
 Get the actions for a given key name and window ID. More...
 

Detailed Description

Interface for mapping buttons to Kodi actions for specific windows.

See also
CJoystickUtils::MakeKeyName

Constructor & Destructor Documentation

◆ ~IWindowKeymap()

virtual IWindowKeymap::~IWindowKeymap ( )
virtualdefault

Member Function Documentation

◆ ControllerID()

virtual std::string IWindowKeymap::ControllerID ( ) const
pure virtual

The controller ID.

This is required because key names are specific to each controller

Implemented in CWindowKeymap.

◆ GetActions()

virtual const KODI::JOYSTICK::KeymapActionGroup & IWindowKeymap::GetActions ( int  windowId,
const std::string &  keyName 
) const
pure virtual

Get the actions for a given key name and window ID.

Parameters
windowIdThe window ID to look up
keyNameThe key name created by CJoystickUtils::MakeKeyName()
Returns
A list of actions associated with the given key for the given window

Implemented in CWindowKeymap.

◆ MapAction()

virtual void IWindowKeymap::MapAction ( int  windowId,
const std::string &  keyName,
KODI::JOYSTICK::KeymapAction  action 
)
pure virtual

Add an action to the keymap for a given key name and window ID.

Parameters
windowIdThe window ID to look up
keyNameThe key name created by CJoystickUtils::MakeKeyName()
actionThe action to map

Implemented in CWindowKeymap.


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