added comment for key repeatModes

This commit is contained in:
KlausMu 2024-01-23 17:56:43 +01:00
parent 87573950e8
commit c35711a8d2

View file

@ -56,11 +56,16 @@ void init_keys(void) {
} }
enum repeatModes { enum repeatModes {
SHORT, // if you short press or old a key on the keypad, only one single command from keyCommands_short is sent -> best used if you do not want a command to be sent more than once, even if you press the key (too) long // if you short press or hold a key on the keypad, only one single command from keyCommands_short is sent
SHORT_REPEATED, // if you hold a key on the keypad, a command from keyCommands_short is sent repeatedly -> best used e.g. for holding the key for "volume up" // -> best used if you do not want a command to be sent more than once, even if you press the key (too) long, e.g. when toggling power
SHORTorLONG, // if you short press a key, a command from keyCommands_short is sent once. SHORT,
// if you hold a key on the keypad, a command from keyCommands_long is sent (no command from keyCommands_short before) // if you hold a key on the keypad, a command from keyCommands_short is sent repeatedly
// -> best used if a long key press should send a different command than a short press // -> best used e.g. for holding the key for "volume up"
SHORT_REPEATED,
// if you short press a key, a command from keyCommands_short is sent once.
// if you hold a key on the keypad, a command from keyCommands_long is sent (no command from keyCommands_short before)
// -> best used if a long key press should send a different command than a short press
SHORTorLONG,
}; };
std::map<char, repeatModes> keyRepeatModes { std::map<char, repeatModes> keyRepeatModes {