touchpad->device->rel.dx = wl_fixed_from_double(dx);
touchpad->device->rel.dy = wl_fixed_from_double(dy);
touchpad->device->pending_events |=
- EVDEV_RELATIVE_MOTION | EVDEV_SYN;
+ EVDEV_RELATIVE_MOTION | EVDEV_SYN_OR_SLOT;
} else if (touchpad->finger_state == TOUCHPAD_FINGERS_TWO) {
if (dx != 0.0)
notify_axis(touchpad->device->seat,
switch (e->code) {
case ABS_MT_SLOT:
device->mt.slot = e->value;
+ device->pending_events |= EVDEV_SYN_OR_SLOT;
break;
case ABS_MT_TRACKING_ID:
if (e->value >= 0)
int32_t cx, cy;
int slot;
- if (!(device->pending_events & EVDEV_SYN))
+ if (!(device->pending_events & EVDEV_SYN_OR_SLOT))
return;
slot = device->mt.slot;
- device->pending_events &= ~EVDEV_SYN;
+ device->pending_events &= ~EVDEV_SYN_OR_SLOT;
if (device->pending_events & EVDEV_RELATIVE_MOTION) {
notify_motion(master, time, device->rel.dx, device->rel.dy);
device->pending_events &= ~EVDEV_RELATIVE_MOTION;
evdev_process_key(device, event, time);
break;
case EV_SYN:
- device->pending_events |= EVDEV_SYN;
+ device->pending_events |= EVDEV_SYN_OR_SLOT;
break;
}
}
EVDEV_ABSOLUTE_MT_MOTION = (1 << 2),
EVDEV_ABSOLUTE_MT_UP = (1 << 3),
EVDEV_RELATIVE_MOTION = (1 << 4),
- EVDEV_SYN = (1 << 5),
+ EVDEV_SYN_OR_SLOT = (1 << 5),
};
enum evdev_device_capability {