Constify the syms_out argument to xkb_key_get_syms()
The caller should not mess around with these as they come directly from our internal structs. Signed-off-by: Ran Benita <ran234@gmail.com>master
parent
467d7bb64e
commit
073a21076c
|
@ -447,7 +447,7 @@ xkb_state_update_key(struct xkb_state *state, xkb_keycode_t key,
|
||||||
*/
|
*/
|
||||||
_X_EXPORT unsigned int
|
_X_EXPORT unsigned int
|
||||||
xkb_key_get_syms(struct xkb_state *state, xkb_keycode_t key,
|
xkb_key_get_syms(struct xkb_state *state, xkb_keycode_t key,
|
||||||
xkb_keysym_t **syms_out);
|
const xkb_keysym_t **syms_out);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Modifier and group types for state objects. This enum is bitmaskable,
|
* Modifier and group types for state objects. This enum is bitmaskable,
|
||||||
|
|
|
@ -302,7 +302,7 @@ xkb_key_get_group(struct xkb_state *state, xkb_keycode_t key)
|
||||||
*/
|
*/
|
||||||
unsigned int
|
unsigned int
|
||||||
xkb_key_get_syms_by_level(struct xkb_keymap *xkb, xkb_keycode_t key, unsigned int group,
|
xkb_key_get_syms_by_level(struct xkb_keymap *xkb, xkb_keycode_t key, unsigned int group,
|
||||||
unsigned int level, xkb_keysym_t **syms_out)
|
unsigned int level, const xkb_keysym_t **syms_out)
|
||||||
{
|
{
|
||||||
int num_syms;
|
int num_syms;
|
||||||
|
|
||||||
|
@ -329,7 +329,7 @@ err:
|
||||||
*/
|
*/
|
||||||
unsigned int
|
unsigned int
|
||||||
xkb_key_get_syms(struct xkb_state *state, xkb_keycode_t key,
|
xkb_key_get_syms(struct xkb_state *state, xkb_keycode_t key,
|
||||||
xkb_keysym_t **syms_out)
|
const xkb_keysym_t **syms_out)
|
||||||
{
|
{
|
||||||
struct xkb_keymap *xkb = state->xkb;
|
struct xkb_keymap *xkb = state->xkb;
|
||||||
int group;
|
int group;
|
||||||
|
|
|
@ -75,6 +75,6 @@ XkbcFreeServerMap(struct xkb_keymap * xkb);
|
||||||
extern unsigned int
|
extern unsigned int
|
||||||
xkb_key_get_syms_by_level(struct xkb_keymap *xkb, xkb_keycode_t key,
|
xkb_key_get_syms_by_level(struct xkb_keymap *xkb, xkb_keycode_t key,
|
||||||
unsigned int group, unsigned int level,
|
unsigned int group, unsigned int level,
|
||||||
xkb_keysym_t **syms_out);
|
const xkb_keysym_t **syms_out);
|
||||||
|
|
||||||
#endif /* _XKBALLOC_H_ */
|
#endif /* _XKBALLOC_H_ */
|
||||||
|
|
|
@ -903,7 +903,7 @@ static struct xkb_sym_interpret *
|
||||||
FindInterpForKey(struct xkb_keymap *xkb, xkb_keycode_t key, uint32_t group, uint32_t level)
|
FindInterpForKey(struct xkb_keymap *xkb, xkb_keycode_t key, uint32_t group, uint32_t level)
|
||||||
{
|
{
|
||||||
struct xkb_sym_interpret *ret = NULL;
|
struct xkb_sym_interpret *ret = NULL;
|
||||||
xkb_keysym_t *syms;
|
const xkb_keysym_t *syms;
|
||||||
int num_syms;
|
int num_syms;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue