Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
KODI::KEYMAP::IKeymapHandler Class Referenceabstract

Interface for a class working with a keymap. More...

#include <IKeymapHandler.h>

Inheritance diagram for KODI::KEYMAP::IKeymapHandler:
KODI::KEYMAP::CKeymapHandler

Public Member Functions

virtual ~IKeymapHandler ()=default
 
virtual bool HotkeysPressed (const std::set< std::string > &keyNames) const =0
 Get the pressed state of the given keys.
 
virtual std::string GetLastPressed () const =0
 Get the key name of the last button pressed.
 
virtual void OnPress (const std::string &keyName)=0
 Called when a key has emitted an action after bring pressed.
 

Detailed Description

Interface for a class working with a keymap.

Constructor & Destructor Documentation

◆ ~IKeymapHandler()

virtual KODI::KEYMAP::IKeymapHandler::~IKeymapHandler ( )
virtualdefault

Member Function Documentation

◆ GetLastPressed()

virtual std::string KODI::KEYMAP::IKeymapHandler::GetLastPressed ( ) const
pure virtual

Get the key name of the last button pressed.

Returns
The key name of the last-pressed button, or empty if no button is pressed

Implemented in KODI::KEYMAP::CKeymapHandler.

◆ HotkeysPressed()

virtual bool KODI::KEYMAP::IKeymapHandler::HotkeysPressed ( const std::set< std::string > & keyNames) const
pure virtual

Get the pressed state of the given keys.

Parameters
keyNamesThe key names
Returns
True if all keys are pressed or no keys are given, false otherwise

Implemented in KODI::KEYMAP::CKeymapHandler.

◆ OnPress()

virtual void KODI::KEYMAP::IKeymapHandler::OnPress ( const std::string & keyName)
pure virtual

Called when a key has emitted an action after bring pressed.

Parameters
keyNamethe key name that emitted the action

Implemented in KODI::KEYMAP::CKeymapHandler.


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