Merge pull request #478 from martinetd/modifiers

wlr_seat: send keyboard modifiers to the right client on enter
This commit is contained in:
Drew DeVault 2017-12-10 09:07:31 -05:00 committed by GitHub
commit 8ccb5b0b66
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -860,7 +860,6 @@ void wlr_seat_keyboard_enter(struct wlr_seat *seat,
surface->resource, &keys);
wl_array_release(&keys);
wlr_seat_keyboard_send_modifiers(seat);
wlr_seat_client_send_selection(client);
}
@ -882,6 +881,12 @@ void wlr_seat_keyboard_enter(struct wlr_seat *seat,
seat->keyboard_state.focused_client = client;
seat->keyboard_state.focused_surface = surface;
if (client && client->keyboard && seat->keyboard_state.keyboard) {
// tell new client about any modifier change last,
// as it targets seat->keyboard_state.focused_client
wlr_seat_keyboard_send_modifiers(seat);
}
}
void wlr_seat_keyboard_notify_enter(struct wlr_seat *seat, struct