test: use flag instead of hardcoded value in examples

master
Nils 2020-03-25 08:43:41 +00:00 committed by GitHub
parent 8a1709a411
commit 0f1cae0cc4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 3 deletions

View File

@ -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 {

View File

@ -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) {

View File

@ -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;