test: use flag instead of hardcoded value in examples
parent
8a1709a411
commit
0f1cae0cc4
|
@ -453,7 +453,8 @@ main(int argc, char *argv[])
|
||||||
goto err_ctx;
|
goto err_ctx;
|
||||||
}
|
}
|
||||||
keymap = xkb_keymap_new_from_file(ctx, file,
|
keymap = xkb_keymap_new_from_file(ctx, file,
|
||||||
XKB_KEYMAP_FORMAT_TEXT_V1, 0);
|
XKB_KEYMAP_FORMAT_TEXT_V1,
|
||||||
|
XKB_KEYMAP_COMPILE_NO_FLAGS);
|
||||||
fclose(file);
|
fclose(file);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|
|
@ -339,7 +339,8 @@ kbd_keymap(void *data, struct wl_keyboard *wl_kbd, uint32_t format,
|
||||||
}
|
}
|
||||||
|
|
||||||
seat->keymap = xkb_keymap_new_from_buffer(seat->inter->ctx, buf, size - 1,
|
seat->keymap = xkb_keymap_new_from_buffer(seat->inter->ctx, buf, size - 1,
|
||||||
XKB_KEYMAP_FORMAT_TEXT_V1, 0);
|
XKB_KEYMAP_FORMAT_TEXT_V1,
|
||||||
|
XKB_KEYMAP_COMPILE_NO_FLAGS);
|
||||||
munmap(buf, size);
|
munmap(buf, size);
|
||||||
close(fd);
|
close(fd);
|
||||||
if (!seat->keymap) {
|
if (!seat->keymap) {
|
||||||
|
|
|
@ -123,7 +123,8 @@ update_keymap(struct keyboard *kbd)
|
||||||
struct xkb_state *new_state;
|
struct xkb_state *new_state;
|
||||||
|
|
||||||
new_keymap = xkb_x11_keymap_new_from_device(kbd->ctx, kbd->conn,
|
new_keymap = xkb_x11_keymap_new_from_device(kbd->ctx, kbd->conn,
|
||||||
kbd->device_id, 0);
|
kbd->device_id,
|
||||||
|
XKB_KEYMAP_COMPILE_NO_FLAGS);
|
||||||
if (!new_keymap)
|
if (!new_keymap)
|
||||||
goto err_out;
|
goto err_out;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue