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

Customizes the environment in which keymapping is performed. More...

#include <IKeymapEnvironment.h>

Inheritance diagram for KODI::KEYMAP::IKeymapEnvironment:
KODI::GAME::CPortInput KODI::KEYMAP::CKeymapEnvironment

Public Member Functions

virtual ~IKeymapEnvironment ()=default
 
virtual int GetWindowID () const =0
 Get the window ID for which actions should be translated.
 
virtual void SetWindowID (int windowId)=0
 Set the window ID.
 
virtual int GetFallthrough (int windowId) const =0
 Get the fallthrough window to when a key definition is missing.
 
virtual bool UseGlobalFallthrough () const =0
 Specify if the global keymap should be used when the window and fallback window are undefined.
 
virtual bool UseEasterEgg () const =0
 Specify if the agent should monitor for easter egg presses.
 

Detailed Description

Customizes the environment in which keymapping is performed.

By overriding GetWindowID() and GetFallthrough(), an agent can customize the behavior of the keymap by forcing a window and preventing the use of a fallback window, respectively.

An agent can also inform the keymap that it isn't accepting input currently, allowing the input to fall through to the next input handler.

Constructor & Destructor Documentation

◆ ~IKeymapEnvironment()

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

Member Function Documentation

◆ GetFallthrough()

virtual int KODI::KEYMAP::IKeymapEnvironment::GetFallthrough ( int windowId) const
pure virtual

Get the fallthrough window to when a key definition is missing.

Parameters
windowIdThe window ID
Returns
The window ID, or -1 for no fallthrough

Implemented in KODI::GAME::CPortInput, and KODI::KEYMAP::CKeymapEnvironment.

◆ GetWindowID()

virtual int KODI::KEYMAP::IKeymapEnvironment::GetWindowID ( ) const
pure virtual

Get the window ID for which actions should be translated.

Returns
The window ID

Implemented in KODI::GAME::CPortInput, and KODI::KEYMAP::CKeymapEnvironment.

◆ SetWindowID()

virtual void KODI::KEYMAP::IKeymapEnvironment::SetWindowID ( int windowId)
pure virtual

Set the window ID.

Parameters
Thewindow ID, used for translating actions

Implemented in KODI::GAME::CPortInput, and KODI::KEYMAP::CKeymapEnvironment.

◆ UseEasterEgg()

virtual bool KODI::KEYMAP::IKeymapEnvironment::UseEasterEgg ( ) const
pure virtual

Specify if the agent should monitor for easter egg presses.

Implemented in KODI::GAME::CPortInput, and KODI::KEYMAP::CKeymapEnvironment.

◆ UseGlobalFallthrough()

virtual bool KODI::KEYMAP::IKeymapEnvironment::UseGlobalFallthrough ( ) const
pure virtual

Specify if the global keymap should be used when the window and fallback window are undefined.

Implemented in KODI::GAME::CPortInput, and KODI::KEYMAP::CKeymapEnvironment.


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