[PATCH xserver] XMir DDX

Daniel Stone daniel at fooishbar.org
Thu May 5 08:04:25 UTC 2016


Hi,

On 5 May 2016 at 06:40, Peter Hutterer <peter.hutterer at who-t.net> wrote:
> On Fri, Apr 29, 2016 at 11:11:20AM +0200, Robert Ancell wrote:
>> +    for (i = 0; i < 3; ++i) {
>> +        MirPointerButton mir_button = map[i].mir_button;
>> +        int x_button = map[i].x_button;
>> +        int oldstate = BitIsOn(dev->button->down, x_button) ?
>> +                       ButtonPress : ButtonRelease;
>> +        int newstate = mir_pointer_event_button_state(pev, mir_button) ?
>> +                       ButtonPress : ButtonRelease;
>> +
>> +        if (oldstate != newstate)
>> +            QueuePointerEvents(dev, newstate, x_button, 0, &mask);
>> +    }
>
> doesn't your event contain the actual button event? why do you need to check
> the device state and bitmask around it?

down is also the wrong thing to check; it should be using postdown.

Cheers,
Daniel


More information about the xorg-devel mailing list