Rename ACTION_TYPE_LAST to _ACTION_TYPE_NUM_ENTRIES
It's not really "last" per-se, and we use this other format in some other enums. Signed-off-by: Ran Benita <ran234@gmail.com>master
parent
16425ffad9
commit
18a0ead587
|
@ -150,7 +150,7 @@ enum xkb_action_type {
|
|||
ACTION_TYPE_CTRL_LOCK,
|
||||
ACTION_TYPE_KEY_REDIRECT,
|
||||
ACTION_TYPE_PRIVATE,
|
||||
ACTION_TYPE_LAST
|
||||
_ACTION_TYPE_NUM_ENTRIES
|
||||
};
|
||||
|
||||
enum xkb_action_flags {
|
||||
|
|
|
@ -107,8 +107,7 @@ NewActionsInfo(void)
|
|||
if (!info)
|
||||
return NULL;
|
||||
|
||||
/* This includes PrivateAction. */
|
||||
for (type = 0; type < ACTION_TYPE_LAST; type++)
|
||||
for (type = 0; type < _ACTION_TYPE_NUM_ENTRIES; type++)
|
||||
info->actions[type].type = type;
|
||||
|
||||
/* Apply some "factory defaults". */
|
||||
|
@ -815,7 +814,7 @@ typedef bool (*actionHandler)(struct xkb_keymap *keymap,
|
|||
const ExprDef *array_ndx,
|
||||
const ExprDef *value);
|
||||
|
||||
static const actionHandler handleAction[ACTION_TYPE_LAST] = {
|
||||
static const actionHandler handleAction[_ACTION_TYPE_NUM_ENTRIES] = {
|
||||
[ACTION_TYPE_NONE] = HandleNoAction,
|
||||
[ACTION_TYPE_MOD_SET] = HandleSetLatchMods,
|
||||
[ACTION_TYPE_MOD_LATCH] = HandleSetLatchMods,
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
* modified within the files (see calls to SetActionField).
|
||||
*/
|
||||
typedef struct {
|
||||
union xkb_action actions[ACTION_TYPE_LAST];
|
||||
union xkb_action actions[_ACTION_TYPE_NUM_ENTRIES];
|
||||
} ActionsInfo;
|
||||
|
||||
ActionsInfo *
|
||||
|
|
Loading…
Reference in New Issue