openATV enigma2
openATV is an open source SetTopBox Graphical user interface.
eRCDevice Class Referenceabstract

A remote control. More...

#include <rc.h>

Inheritance diagram for eRCDevice:
eHdmiCECDevice eRCConsole eRCDeviceDBoxButton eRCDeviceDBoxNew eRCDeviceDBoxOld eRCDeviceDreambox2 eRCDeviceDreamboxButton eRCDeviceInputDev eSDLInputDevice

Public Member Functions

 eRCDevice (std::string id, eRCDriver *input)
 Constructs a new remote control. More...
 
virtual ~eRCDevice ()
 
virtual void handleCode (long code)=0
 Handles a device specific code. More...
 
virtual const char * getDescription () const =0
 Get user readable description. More...
 
const std::string getIdentifier () const
 
virtual void setExclusive (bool b)
 Get a description for a specific key. More...
 
virtual int setKeyMapping (const std::unordered_map< unsigned int, unsigned int > &remaps)
 set key remappngs. More...
 

Protected Attributes

eRCInputinput
 
eRCDriverdriver
 
std::string id
 

Detailed Description

A remote control.

Handles one remote control. Gets codes from a eRCDriver. Produces events in eRCInput.

Constructor & Destructor Documentation

◆ eRCDevice()

eRCDevice::eRCDevice ( std::string  id,
eRCDriver input 
)

Constructs a new remote control.

Parameters
idThe identifier of the RC, for use in settings.
inputThe eRCDriver where this remote gets its codes from.

◆ ~eRCDevice()

eRCDevice::~eRCDevice ( )
virtual

Member Function Documentation

◆ getDescription()

virtual const char* eRCDevice::getDescription ( ) const
pure virtual

◆ getIdentifier()

const std::string eRCDevice::getIdentifier ( ) const
inline

◆ handleCode()

virtual void eRCDevice::handleCode ( long  code)
pure virtual

Handles a device specific code.

Generates events in eRCInput. code is highly device- and driver dependant. For Example, it might be 16bit codes with one bit make/break or special codes for repeat.

Implemented in eRCDeviceInputDev, eRCConsole, eHdmiCECDevice, and eSDLInputDevice.

◆ setExclusive()

virtual void eRCDevice::setExclusive ( bool  b)
inlinevirtual

Get a description for a specific key.

Parameters
keyThe key to get the description for.
Returns
User readable description of given key.

Reimplemented in eRCDeviceInputDev.

◆ setKeyMapping()

int eRCDevice::setKeyMapping ( const std::unordered_map< unsigned int, unsigned int > &  remaps)
virtual

set key remappngs.

Parameters
remapsThe the keyy remappings.
Returns
The status indicators defined in eRCInput.

Reimplemented in eRCDeviceInputDev.

Member Data Documentation

◆ driver

eRCDriver* eRCDevice::driver
protected

◆ id

std::string eRCDevice::id
protected

◆ input

eRCInput* eRCDevice::input
protected

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