mirror of
https://gitlab.freedesktop.org/libevdev/libevdev.git
synced 2025-12-26 16:50:07 +01:00
cosmetic: fix a couple of duplicate/missing empty lines
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
4ba296cf90
commit
4160d94baf
15 changed files with 5 additions and 30 deletions
|
|
@ -181,7 +181,6 @@ queue_peek(struct libevdev *dev, size_t idx, struct input_event *ev)
|
|||
return 0;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Shift the first n elements into ev and return the number of elements
|
||||
* shifted.
|
||||
|
|
@ -293,7 +292,6 @@ queue_set_num_elements(struct libevdev *dev, size_t nelem)
|
|||
max = libevdev_event_type_get_max(type); \
|
||||
break;
|
||||
|
||||
|
||||
static inline int
|
||||
type_to_mask_const(const struct libevdev *dev, unsigned int type, const unsigned long **mask)
|
||||
{
|
||||
|
|
@ -342,4 +340,3 @@ type_to_mask(struct libevdev *dev, unsigned int type, unsigned long **mask)
|
|||
|
||||
#undef max_mask
|
||||
#endif
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,6 @@
|
|||
* OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
|
||||
struct libevdev_uinput {
|
||||
int fd; /**< file descriptor to uinput */
|
||||
int fd_is_managed; /**< do we need to close it? */
|
||||
|
|
|
|||
|
|
@ -271,8 +271,6 @@ fetch_syspath_and_devnode(struct libevdev_uinput *uinput_dev)
|
|||
return uinput_dev->devnode ? 0 : -1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
LIBEVDEV_EXPORT int
|
||||
libevdev_uinput_create_from_device(const struct libevdev *dev, int fd, struct libevdev_uinput** uinput_dev)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -45,7 +45,6 @@
|
|||
_a > _b ? _a : _b; \
|
||||
})
|
||||
|
||||
|
||||
static inline bool
|
||||
startswith(const char *str, size_t len, const char *prefix, size_t plen)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -160,7 +160,6 @@ _libevdev_log_msg(const struct libevdev *dev,
|
|||
else if (unlikely(log_data.device_handler))
|
||||
abort(); /* Seppuku, see above */
|
||||
|
||||
|
||||
va_start(args, format);
|
||||
if (dev && dev->log.device_handler)
|
||||
dev->log.device_handler(dev, priority, dev->log.userdata, file, line, func, format, args);
|
||||
|
|
@ -682,7 +681,6 @@ sync_mt_state(struct libevdev *dev, int create_events)
|
|||
set_bit(slot_update, AXISBIT(slot, ABS_MT_SLOT));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1050,7 +1048,6 @@ libevdev_next_event(struct libevdev *dev, unsigned int flags, struct input_event
|
|||
goto out;
|
||||
}
|
||||
|
||||
|
||||
if (queue_shift(dev, ev) != 0)
|
||||
return -EAGAIN;
|
||||
|
||||
|
|
@ -1136,7 +1133,6 @@ STRING_SETTER(name)
|
|||
STRING_SETTER(phys)
|
||||
STRING_SETTER(uniq)
|
||||
|
||||
|
||||
#define PRODUCT_GETTER(name) \
|
||||
LIBEVDEV_EXPORT int libevdev_get_id_##name(const struct libevdev *dev) \
|
||||
{ \
|
||||
|
|
|
|||
|
|
@ -1032,7 +1032,6 @@ int libevdev_change_fd(struct libevdev* dev, int fd);
|
|||
*/
|
||||
int libevdev_get_fd(const struct libevdev* dev);
|
||||
|
||||
|
||||
/**
|
||||
* @ingroup events
|
||||
*/
|
||||
|
|
@ -1054,6 +1053,7 @@ enum libevdev_read_status {
|
|||
*/
|
||||
LIBEVDEV_READ_STATUS_SYNC = 1
|
||||
};
|
||||
|
||||
/**
|
||||
* @ingroup events
|
||||
*
|
||||
|
|
@ -1385,6 +1385,7 @@ int libevdev_has_event_code(const struct libevdev *dev, unsigned int type, unsig
|
|||
* @note This function is signal-safe.
|
||||
*/
|
||||
int libevdev_get_abs_minimum(const struct libevdev *dev, unsigned int code);
|
||||
|
||||
/**
|
||||
* @ingroup bits
|
||||
*
|
||||
|
|
@ -1398,6 +1399,7 @@ int libevdev_get_abs_minimum(const struct libevdev *dev, unsigned int code);
|
|||
* @note This function is signal-safe.
|
||||
*/
|
||||
int libevdev_get_abs_maximum(const struct libevdev *dev, unsigned int code);
|
||||
|
||||
/**
|
||||
* @ingroup bits
|
||||
*
|
||||
|
|
@ -1411,6 +1413,7 @@ int libevdev_get_abs_maximum(const struct libevdev *dev, unsigned int code);
|
|||
* @note This function is signal-safe.
|
||||
*/
|
||||
int libevdev_get_abs_fuzz(const struct libevdev *dev, unsigned int code);
|
||||
|
||||
/**
|
||||
* @ingroup bits
|
||||
*
|
||||
|
|
@ -1424,6 +1427,7 @@ int libevdev_get_abs_fuzz(const struct libevdev *dev, unsigned int code);
|
|||
* @note This function is signal-safe.
|
||||
*/
|
||||
int libevdev_get_abs_flat(const struct libevdev *dev, unsigned int code);
|
||||
|
||||
/**
|
||||
* @ingroup bits
|
||||
*
|
||||
|
|
@ -1851,7 +1855,6 @@ int libevdev_disable_event_code(struct libevdev *dev, unsigned int type, unsigne
|
|||
*/
|
||||
int libevdev_kernel_set_abs_info(struct libevdev *dev, unsigned int code, const struct input_absinfo *abs);
|
||||
|
||||
|
||||
/**
|
||||
* @ingroup kernel
|
||||
*/
|
||||
|
|
@ -2147,7 +2150,6 @@ int libevdev_property_from_name_n(const char *name, size_t len);
|
|||
*/
|
||||
int libevdev_get_repeat(const struct libevdev *dev, int *delay, int *period);
|
||||
|
||||
|
||||
/********* DEPRECATED SECTION *********/
|
||||
#if defined(__GNUC__) && __GNUC__ >= 4
|
||||
#define LIBEVDEV_DEPRECATED __attribute__ ((deprecated))
|
||||
|
|
|
|||
|
|
@ -25,7 +25,6 @@
|
|||
|
||||
#define DEFAULT_IDS NULL
|
||||
|
||||
|
||||
struct uinput_device* uinput_device_new(const char *name);
|
||||
int uinput_device_new_with_events(struct uinput_device **dev, const char *name, const struct input_id *ids, ...);
|
||||
int uinput_device_new_with_events_v(struct uinput_device **dev, const char *name, const struct input_id *ids, va_list args);
|
||||
|
|
|
|||
|
|
@ -32,7 +32,6 @@
|
|||
|
||||
#include "test-common-uinput.h"
|
||||
|
||||
|
||||
int test_create_device(struct uinput_device **uidev,
|
||||
struct libevdev **dev,
|
||||
...);
|
||||
|
|
|
|||
|
|
@ -298,4 +298,3 @@ event_name_suite(void)
|
|||
|
||||
return s;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -357,4 +357,3 @@ queue_suite(void)
|
|||
|
||||
return s;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -533,7 +533,6 @@ START_TEST(test_syn_delta_mt)
|
|||
abs[3].value = ABS_MT_POSITION_Y;
|
||||
abs[3].maximum = 1000;
|
||||
|
||||
|
||||
abs[4].value = ABS_MT_SLOT;
|
||||
abs[4].maximum = 1;
|
||||
abs[5].value = ABS_MT_TRACKING_ID;
|
||||
|
|
@ -648,7 +647,6 @@ START_TEST(test_syn_delta_mt_reset_slot)
|
|||
abs[3].value = ABS_MT_POSITION_Y;
|
||||
abs[3].maximum = 1000;
|
||||
|
||||
|
||||
abs[4].value = ABS_MT_SLOT;
|
||||
abs[4].maximum = 1;
|
||||
abs[5].value = ABS_MT_TRACKING_ID;
|
||||
|
|
@ -1109,7 +1107,6 @@ START_TEST(test_syn_delta_late_sync)
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
/* Now we basically re-do the exact same test, just with the
|
||||
tracking ID order inverted */
|
||||
|
||||
|
|
@ -1193,7 +1190,6 @@ START_TEST(test_syn_delta_late_sync)
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
uinput_device_free(uidev);
|
||||
libevdev_free(dev);
|
||||
}
|
||||
|
|
@ -1500,7 +1496,6 @@ START_TEST(test_event_values_invalid)
|
|||
ck_assert_int_eq(libevdev_fetch_event_value(dev, EV_REL, REL_Z, &value), 0);
|
||||
ck_assert_int_eq(value, 0xab);
|
||||
|
||||
|
||||
uinput_device_free(uidev);
|
||||
libevdev_free(dev);
|
||||
|
||||
|
|
@ -2168,4 +2163,3 @@ libevdev_events(void)
|
|||
|
||||
return s;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -262,7 +262,6 @@ START_TEST(test_input_props)
|
|||
rc = libevdev_new_from_fd(uinput_device_get_fd(uidev), &dev);
|
||||
ck_assert_msg(rc == 0, "Failed to create device: %s", strerror(-rc));
|
||||
|
||||
|
||||
for (i = 0; i < INPUT_PROP_CNT; i++) {
|
||||
if (i == INPUT_PROP_DIRECT || i == INPUT_PROP_BUTTONPAD)
|
||||
ck_assert_int_eq(libevdev_has_property(dev, i), 1);
|
||||
|
|
@ -577,7 +576,6 @@ START_TEST(test_device_get_abs_info)
|
|||
uidev = uinput_device_new(TEST_DEVICE_NAME);
|
||||
ck_assert(uidev != NULL);
|
||||
|
||||
|
||||
abs.minimum = 0;
|
||||
abs.maximum = 1000;
|
||||
abs.fuzz = 1;
|
||||
|
|
@ -1202,4 +1200,3 @@ libevdev_has_event_test(void)
|
|||
|
||||
return s;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -529,7 +529,6 @@ START_TEST(test_set_clock_id_invalid_fd)
|
|||
}
|
||||
END_TEST
|
||||
|
||||
|
||||
START_TEST(test_clock_id_events)
|
||||
{
|
||||
struct uinput_device* uidev;
|
||||
|
|
|
|||
|
|
@ -206,7 +206,6 @@ set_led(struct libevdev *dev)
|
|||
return;
|
||||
}
|
||||
|
||||
|
||||
rc = libevdev_kernel_set_led_value(dev, led, state);
|
||||
if (rc != 0)
|
||||
fprintf(stderr,
|
||||
|
|
|
|||
|
|
@ -193,4 +193,3 @@ int main (int argc, char **argv) {
|
|||
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue