mirror of
https://gitlab.freedesktop.org/libinput/libei.git
synced 2026-05-06 04:48:11 +02:00
parent
d01a39ef82
commit
61d97269ab
1 changed files with 10 additions and 14 deletions
|
|
@ -1355,9 +1355,9 @@ _public_ void
|
|||
ei_device_button_button(struct ei_device *device,
|
||||
uint32_t button, bool is_press)
|
||||
{
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER)) {
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_BUTTON)) {
|
||||
log_bug_client(ei_device_get_context(device),
|
||||
"%s: device is not a pointer", __func__);
|
||||
"%s: device is not a button device", __func__);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -1381,10 +1381,9 @@ ei_device_button_button(struct ei_device *device,
|
|||
_public_ void
|
||||
ei_device_scroll_delta(struct ei_device *device, double x, double y)
|
||||
{
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER) &&
|
||||
!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER_ABSOLUTE)) {
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_SCROLL)) {
|
||||
log_bug_client(ei_device_get_context(device),
|
||||
"%s: device is not a (absolute) pointer", __func__);
|
||||
"%s: device is not scroll device", __func__);
|
||||
}
|
||||
|
||||
if (device->state != EI_DEVICE_STATE_EMULATING) {
|
||||
|
|
@ -1402,10 +1401,9 @@ ei_device_scroll_delta(struct ei_device *device, double x, double y)
|
|||
_public_ void
|
||||
ei_device_scroll_stop(struct ei_device *device, bool x, bool y)
|
||||
{
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER) &&
|
||||
!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER_ABSOLUTE)) {
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_SCROLL)) {
|
||||
log_bug_client(ei_device_get_context(device),
|
||||
"%s: device is not a (absolute) pointer", __func__);
|
||||
"%s: device is not scroll device", __func__);
|
||||
}
|
||||
|
||||
if (device->state != EI_DEVICE_STATE_EMULATING) {
|
||||
|
|
@ -1432,10 +1430,9 @@ ei_device_scroll_stop(struct ei_device *device, bool x, bool y)
|
|||
_public_ void
|
||||
ei_device_scroll_cancel(struct ei_device *device, bool x, bool y)
|
||||
{
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER) &&
|
||||
!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER_ABSOLUTE)) {
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_SCROLL)) {
|
||||
log_bug_client(ei_device_get_context(device),
|
||||
"%s: device is not a (absolute) pointer", __func__);
|
||||
"%s: device is not scroll device", __func__);
|
||||
}
|
||||
|
||||
if (device->state != EI_DEVICE_STATE_EMULATING) {
|
||||
|
|
@ -1466,10 +1463,9 @@ ei_device_scroll_cancel(struct ei_device *device, bool x, bool y)
|
|||
_public_ void
|
||||
ei_device_scroll_discrete(struct ei_device *device, int32_t x, int32_t y)
|
||||
{
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER) &&
|
||||
!ei_device_has_capability(device, EI_DEVICE_CAP_POINTER_ABSOLUTE)) {
|
||||
if (!ei_device_has_capability(device, EI_DEVICE_CAP_SCROLL)) {
|
||||
log_bug_client(ei_device_get_context(device),
|
||||
"%s: device is not a (absolute) pointer", __func__);
|
||||
"%s: device is not scroll device", __func__);
|
||||
}
|
||||
|
||||
if (device->state != EI_DEVICE_STATE_EMULATING) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue