swc

Unnamed repository; edit this file 'description' to name the repository.
git clone git://git.nihaljere.xyz/swc
Log | Files | Refs | README | LICENSE

commit fdd795ec5ccf97d006950d3218d3460a53de56a7
parent 1f194489fa1e55dd8d666b13e372566a703b5757
Author: Michael Forney <mforney@mforney.org>
Date:   Sun,  3 Aug 2014 14:18:47 -0700

keyboard: Send modifiers to clients on enter

Otherwise, the client's state of the modifiers will remain how they were
the last time the modifiers changed when the client had focus.

Diffstat:
Mlibswc/keyboard.c | 3+++
1 file changed, 3 insertions(+), 0 deletions(-)

diff --git a/libswc/keyboard.c b/libswc/keyboard.c @@ -40,9 +40,12 @@ static void enter(struct input_focus_handler * handler, { struct keyboard * keyboard = wl_container_of(handler, keyboard, focus_handler); + struct keyboard_modifier_state * state = &keyboard->modifier_state; uint32_t serial; serial = wl_display_next_serial(swc.display); + wl_keyboard_send_modifiers(resource, serial, state->depressed, + state->locked, state->latched, state->group); wl_keyboard_send_enter(resource, serial, view->surface->resource, &keyboard->client_keys); }