The KeyRepeatConcept class defines the key-repeat gesture handling in Kanzi.
More...
#include <kanzi/core.ui/input/key_input_concept.hpp>
The KeyRepeatConcept class defines the key-repeat gesture handling in Kanzi.
The class holds the methods that enable you to handle key-repeat gestures in your manipulator.
You can use the key-repeat gesture detection mechanism by deriving your class from the KeyRepeatConceptImpl template class.
- Since
- Kanzi 3.8.0
Specifies the key-hold and key-repeat gesture detection mode.
| Enumerator |
|---|
| Disabled |
The key-hold and key-repeat gesture detection is disabled.
|
| KeyHold |
Handle only key-hold gestures.
|
| KeyHoldAndRepeat |
Handle both key-hold and key-repeat gestures.
|
| virtual kanzi::KeyRepeatConcept::~KeyRepeatConcept |
( |
| ) |
|
|
virtualdefault |
| kanzi::KeyRepeatConcept::KeyRepeatConcept |
( |
| ) |
|
|
explicitprotecteddefault |
| DetectionMode kanzi::KeyRepeatConcept::getKeyRepeatDetectionMode |
( |
| ) |
const |
|
inline |
Returns the current key-hold and key-repeat gesture detection mode.
- Returns
- The current key-hold and key-repeat gesture detection mode. The default value is #KeyHoldAndRepeat.
| chrono::milliseconds kanzi::KeyRepeatConcept::getKeyHoldTimeout |
( |
| ) |
const |
Returns the time, in milliseconds, that Kanzi waits before it detects a key-hold gesture.
- Returns
- The time, in milliseconds, that Kanzi waits before it detects a key-hold gesture. The default is 500 milliseconds.
| void kanzi::KeyRepeatConcept::setKeyHoldTimeout |
( |
chrono::milliseconds |
timeout | ) |
|
Sets the time that Kanzi waits to detect a key-hold gesture.
- Parameters
-
| timeout | The time, in milliseconds, that Kanzi waits to detect a key-hold gesture. This value must be greater than zero. |
| chrono::milliseconds kanzi::KeyRepeatConcept::getKeyRepeatInterval |
( |
| ) |
const |
Returns the time, in milliseconds, between key-repeat gesture notifications that Kanzi sends repeatedly.
The key-repeat gesture detection follows after Kanzi detects a key-hold gesture.
- Returns
- The time, in milliseconds, that Kanzi waits between key-repeat gesture notifications. The default is 100 milliseconds.
| void kanzi::KeyRepeatConcept::setKeyRepeatInterval |
( |
chrono::milliseconds |
interval | ) |
|
Sets the time between the key-repeat gesture notifications that Kanzi sends repeatedly.
- Parameters
-
| interval | The time, in milliseconds, that Kanzi waits between key-repeat gesture notifications. This value must be greater than zero. |
Timer handle for the initial key-hold and the key-repeat interval.
| chrono::milliseconds kanzi::KeyRepeatConcept::m_keyHoldTimeout |
|
protected |
| chrono::milliseconds kanzi::KeyRepeatConcept::m_keyRepeatInterval |
|
protected |
Holds the key-repeat setting of the key gesture.
The documentation for this class was generated from the following file: