[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freedesktop-xorg-devel
Subject:    Re: [PATCH xserver] xwayland: Process queued events before making wayland mods effective
From:       Daniel Stone <daniel () fooishbar ! org>
Date:       2016-06-27 7:55:59
Message-ID: CAPj87rNp2L-4wFAf1XTu1DucQ0f=tiovcuTof10QX0m1QRR8PA () mail ! gmail ! com
[Download RAW message or body]

Hi,

On 27 June 2016 at 03:48, Rui Matos <tiagomatos@gmail.com> wrote:
> Since xwayland's initial commit we have had a check to not process
> wayland modifier events while one of our surfaces has keyboard focus
> since the normal xkb event processing keeps our internal modifier
> state up to date and if we use the modifiers we get from the
> compositor we mess up that state.
>
> This was slightly changed in commit
> 10e9116b3f709bec6d6a50446c1341441a0564e4 to allow the xkb group to be
> set from the wayland event while we have focus in case the compositor
> triggers a group switch.
>
> There's a better solution to the original problem though. Processing
> queued events before overriding the xkb state with the compositor's
> allows those events to be sent properly modified to X clients while
> any further events will be modified with the wayland modifiers as
> intended.
>
> This allows us to fully take in the wayland modifiers, including
> depressed ones, which fixes an issue where we wouldn't be aware of
> already pressed modifiers on enter.

This is a good solution, though a better solution would arguably be to
add an event we send down the mi event queue, which carried the
modifier information and was processed with that. But, this works, so:
Reviewed-by: Daniel Stone <daniels@collabora.com>

Cheers,
Daniel
_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic