ScummVM API documentation
hpl::Keyboard Class Reference
Inheritance diagram for hpl::Keyboard:
hpl::iInputDevice

Public Member Functions

 Keyboard (LowLevelInput *)
 
bool KeyIsDown (Common::KeyCode aKey)
 
Common::KeyState GetKey ()
 
bool KeyIsPressed ()
 
int GetModifier ()
 
tString KeyToString (Common::KeyCode eKey)
 
Common::KeyCode StringToKey (tString)
 
void Update ()
 
- Public Member Functions inherited from hpl::iInputDevice
 iInputDevice (tString asName, eInputDeviceType aType)
 
tString GetName ()
 
eInputDeviceType GetType ()
 

Member Function Documentation

◆ KeyIsDown()

bool hpl::Keyboard::KeyIsDown ( Common::KeyCode  aKey)
Parameters
aKeyThe key to check
Returns
true if pressed else false

◆ GetKey()

Common::KeyState hpl::Keyboard::GetKey ( )

Can be checked many times to see all key presses

Returns
key that is currently pressed. eKey_NONE is no key.

◆ KeyIsPressed()

bool hpl::Keyboard::KeyIsPressed ( )
Returns
If ANY key is pressed

◆ GetModifier()

int hpl::Keyboard::GetModifier ( )
Returns
The current modifiers.

◆ KeyToString()

tString hpl::Keyboard::KeyToString ( Common::KeyCode  eKey)
Parameters
eKeyThe key to change to string.
Returns
The name of the key as a string.

◆ StringToKey()

Common::KeyCode hpl::Keyboard::StringToKey ( tString  )
Parameters
tStringNAme of the key
Returns
enum of the key.

◆ Update()

void hpl::Keyboard::Update ( )
virtual

Update the device, called by cInput

Implements hpl::iInputDevice.


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