ScummVM API documentation
Common::KeyboardHardwareInputSet Class Reference

#include <hardware-input.h>

Inheritance diagram for Common::KeyboardHardwareInputSet:
Common::HardwareInputSet

Public Member Functions

 KeyboardHardwareInputSet (const KeyTableEntry *keys, const ModifierTableEntry *modifiers)
 
HardwareInput findHardwareInput (const String &id) const override
 
HardwareInput findHardwareInput (const Event &event) const override
 

Static Public Member Functions

static KeyState normalizeKeyState (const KeyState &keystate)
 

Detailed Description

A keyboard input device

Describes the keys and key + modifiers combinations as HardwareInputs

Member Function Documentation

◆ findHardwareInput() [1/2]

HardwareInput Common::KeyboardHardwareInputSet::findHardwareInput ( const String id) const
overridevirtual

Retrieve a hardware input description from an unique identifier

In case no input was found with the specified id, an empty HardwareInput structure is return with the type set to kHardwareInputTypeInvalid.

Implements Common::HardwareInputSet.

◆ findHardwareInput() [2/2]

HardwareInput Common::KeyboardHardwareInputSet::findHardwareInput ( const Event event) const
overridevirtual

Retrieve a hardware input description from one of the events produced when the input is triggered.

In case the specified event is not produced by this device, an empty HardwareInput structure is return with the type set to kHardwareInputTypeInvalid.

Implements Common::HardwareInputSet.

◆ normalizeKeyState()

static KeyState Common::KeyboardHardwareInputSet::normalizeKeyState ( const KeyState keystate)
static

Transform a keystate into a canonical form that can be used to unambiguously identify the keypress


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