mirror of
https://gitlab.freedesktop.org/libevdev/libevdev.git
synced 2025-12-25 01:10:10 +01:00
Rename pid/vid to product-id and vendor-id
Slightly more expressive and it's not that painful to type. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
parent
0797c0035b
commit
ba90eab419
3 changed files with 6 additions and 6 deletions
|
|
@ -584,12 +584,12 @@ libevdev_get_name(const struct libevdev *dev)
|
|||
return dev->name;
|
||||
}
|
||||
|
||||
int libevdev_get_pid(const struct libevdev *dev)
|
||||
int libevdev_get_product_id(const struct libevdev *dev)
|
||||
{
|
||||
return dev->ids.product;
|
||||
}
|
||||
|
||||
int libevdev_get_vid(const struct libevdev *dev)
|
||||
int libevdev_get_vendor_id(const struct libevdev *dev)
|
||||
{
|
||||
return dev->ids.vendor;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -186,13 +186,13 @@ const char* libevdev_get_name(const struct libevdev *dev);
|
|||
*
|
||||
* @note This function is signal-safe.
|
||||
*/
|
||||
int libevdev_get_pid(const struct libevdev *dev);
|
||||
int libevdev_get_product_id(const struct libevdev *dev);
|
||||
/**
|
||||
* @return The device's vendor ID
|
||||
*
|
||||
* @note This function is signal-safe.
|
||||
*/
|
||||
int libevdev_get_vid(const struct libevdev *dev);
|
||||
int libevdev_get_vendor_id(const struct libevdev *dev);
|
||||
|
||||
/**
|
||||
* @return The device's bus type
|
||||
|
|
|
|||
|
|
@ -133,8 +133,8 @@ main(int argc, char **argv)
|
|||
|
||||
printf("Input device ID: bus %#x vendor %#x product %#x\n",
|
||||
libevdev_get_bustype(dev),
|
||||
libevdev_get_vid(dev),
|
||||
libevdev_get_pid(dev));
|
||||
libevdev_get_vendor_id(dev),
|
||||
libevdev_get_product_id(dev));
|
||||
printf("Input device name: \"%s\"\n", libevdev_get_name(dev));
|
||||
print_bits(dev);
|
||||
print_props(dev);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue