diff options
Diffstat (limited to 'shared.c')
| -rw-r--r-- | shared.c | 16 | 
1 files changed, 16 insertions, 0 deletions
| @@ -45,6 +45,22 @@ get_linux_keycode_by_name(const char *name)  	return NULL;  } +struct linux_input_keycode * +get_linux_keycode_by_value(uint32_t value) +{ +	struct linux_input_keycode *lik = NULL; +	unsigned i; + +	for (i = 0; linux_input_keycodes[i].name; i++) { +		if (linux_input_keycodes[i].value == value) { +			lik = &linux_input_keycodes[i]; +			break; +		} +	} + +	return lik; +} +  int  strtol_strict(const char *str, int *result)  { | 
