ImFusion SDK 4.3
KeyboardEventsReceiver Class Reference

#include <RoboticsPlugin/Include/ImFusion/Robotics/IO/KeyboardEventsReceiver.h>

The class captures and forwards all the events coming from the keyboard (keys pressed, keys released, ..). and can be used to design tracking streams that are controller by the keyboards keys. More...

+ Inheritance diagram for KeyboardEventsReceiver:

Detailed Description

The class captures and forwards all the events coming from the keyboard (keys pressed, keys released, ..). and can be used to design tracking streams that are controller by the keyboards keys.

Public Member Functions

 KeyboardEventsReceiver (QObject *parent, bool blockEventPropagation, uint64_t debouncingTimeoutMs=100)
 
void blockEventPropagation (bool val)
 Whether the reception of keyboard events should not be further propagated.
 

Public Attributes

Signal< int > signalKeyPressed
 The signal emitted when a key is pressed, reporting the id of the pressed keys on the keyboard.
 
Signal< int > signalKeyReleased
 The signal emitted when a key is released, reporting the id of the released key on the keyboard.
 

Protected Member Functions

bool eventFilter (QObject *obj, QEvent *event) override
 

Protected Attributes

std::atomic< bool > m_blockEventPropagation
 
std::map< QEvent::Type, uint64_t > m_lastEventReceived
 
uint64_t m_minEventTimeout
 The minimum time interval that has to be present between two events of the same type to be accepted.
 

Constructor & Destructor Documentation

◆ KeyboardEventsReceiver()

KeyboardEventsReceiver ( QObject * parent,
bool blockEventPropagation,
uint64_t debouncingTimeoutMs = 100 )
Parameters
parentThe parent object of the qWidget
blockEventPropagationWhether the reception of the key press/released event should be propagated further or stopped. If stopped, eventual event filters installed before the current one will not receive any keyboard events.
debouncingTimeoutMsThe accepted timeout between events of the same type. Events occurring within the timeout time from the last event of the same type are not processed

Member Function Documentation

◆ blockEventPropagation()

void blockEventPropagation ( bool val)

Whether the reception of keyboard events should not be further propagated.

Use this functionality with caution, as if you install this event filter as last, preventing propagation of keyboard clicks will disable interactions between the ImFusionSuite GUI and keyboard


The documentation for this class was generated from the following file:
Search Tab / S to search, Esc to close