.orientation = DEFAULT_TOUCH_ORIENTATION
};
- TRACE_BEGIN(evdev_flush_pending_event);
-
slot = device->mt.slot;
slot_data = &device->mt.slots[slot];
switch (device->pending_event) {
case EVDEV_NONE:
- TRACE_END();
return;
case EVDEV_RELATIVE_MOTION:
dx_unaccel = device->rel.dx / ((double) device->dpi /
}
device->pending_event = EVDEV_NONE;
- TRACE_END();
}
static enum evdev_key_type
{
enum evdev_key_type type;
- TRACE_BEGIN(evdev_process_key);
-
/* ignore kernel key repeat */
- if (e->value == 2) {
- TRACE_END();
+ if (e->value == 2)
return;
- }
if (e->code == BTN_TOUCH) {
if (!device->is_mt)
evdev_process_touch_button(device, time, e->value);
- TRACE_END();
return;
}
case EVDEV_KEY_TYPE_KEY:
case EVDEV_KEY_TYPE_BUTTON:
if (!hw_is_key_down(device, e->code)) {
- TRACE_END();
return;
}
}
LIBINPUT_BUTTON_STATE_RELEASED);
break;
}
- TRACE_END();
}
static void
evdev_process_relative(struct evdev_device *device,
struct input_event *e, uint64_t time)
{
- TRACE_BEGIN(evdev_process_relative);
switch (e->code) {
case REL_X:
if (device->pending_event != EVDEV_RELATIVE_MOTION)
0.0);
break;
}
- TRACE_END();
}
static inline void
struct input_event *e,
uint64_t time)
{
- TRACE_BEGIN(evdev_process_absolute);
if (device->is_mt) {
evdev_process_touch(device, e, time);
} else {
evdev_process_absolute_motion(device, e);
}
- TRACE_END();
}
static inline bool
struct evdev_dispatch *dispatch = device->dispatch;
uint64_t time = e->time.tv_sec * 1000ULL + e->time.tv_usec / 1000;
- TRACE_BEGIN(evdev_process_event);
-
dispatch->interface->process(dispatch, device, e, time);
-
- TRACE_END();
}
static inline void
evdev_device_dispatch_one(struct evdev_device *device,
struct input_event *ev)
{
+ TRACE_BEGIN(evdev_device_dispatch_one);
if (!device->mtdev) {
evdev_process_event(device, ev);
} else {
}
}
}
+ TRACE_END();
}
static int