[PATCH weston] Fix "Back", "Forward", and other special mouse buttons in the X11 compositor.
Dima Ryazanov
dima at gmail.com
Wed Feb 4 01:48:38 PST 2015
I actually feel the same way - but kept the old style just in case. I'll
update it.
On Tue, Feb 3, 2015 at 2:36 PM, Peter Hutterer <peter.hutterer at who-t.net>
wrote:
> On Mon, Dec 22, 2014 at 11:51:05AM -0800, Dima Ryazanov wrote:
> > They're off by 4 because of the scroll buttons.
> >
> > (However, if you test them in XWayland, they'll appear to work because
> > XWayland has the same bug; see
> > http://lists.x.org/archives/xorg-devel/2014-December/044987.html)
> >
> > Signed-off-by: Dima Ryazanov <dima at gmail.com>
> > ---
> > src/compositor-x11.c | 5 ++++-
> > 1 file changed, 4 insertions(+), 1 deletion(-)
> >
> > diff --git a/src/compositor-x11.c b/src/compositor-x11.c
> > index 29f2119..af9de6f 100644
> > --- a/src/compositor-x11.c
> > +++ b/src/compositor-x11.c
> > @@ -1015,7 +1015,10 @@ x11_compositor_deliver_button_event(struct
> x11_compositor *c,
> >
> > switch (button_event->detail) {
> > default:
> > - button = button_event->detail + BTN_LEFT - 1;
> > + button = button_event->detail + BTN_SIDE - 8;
> > + break;
> > + case 1:
> > + button = BTN_LEFT;
> > break;
> > case 2:
> > button = BTN_MIDDLE;
> > --
> > 2.1.0
>
> Reviewed-by: Peter Hutterer <peter.hutterer at who-t.net>
> though I'd prefer having the default at the bottom of the switch
> case
>
> Cheers,
> Peter
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20150204/70bbb451/attachment.html>
More information about the wayland-devel
mailing list