mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-05-22 04:38:30 +00:00
Try SDL_UDEV_deviceclass to detect joysticks even if in a container
The udev container issue is mostly to do with device notifications and netlink. The device classification stuff just pokes file in /sys and /run/udev. Doesn't hurt to try it first for classifying joysticks and then fall to the guess heuristics if it fails.
This commit is contained in:
parent
1bf78ed544
commit
6daf2e943f
3 changed files with 42 additions and 22 deletions
|
@ -102,7 +102,7 @@ extern void SDL_UDEV_UnloadLibrary(void);
|
|||
extern int SDL_UDEV_LoadLibrary(void);
|
||||
extern void SDL_UDEV_Poll(void);
|
||||
extern int SDL_UDEV_Scan(void);
|
||||
extern SDL_bool SDL_UDEV_GetProductInfo(const char *device_path, Uint16 *vendor, Uint16 *product, Uint16 *version);
|
||||
extern SDL_bool SDL_UDEV_GetProductInfo(const char *device_path, Uint16 *vendor, Uint16 *product, Uint16 *version, int *class);
|
||||
extern int SDL_UDEV_AddCallback(SDL_UDEV_Callback cb);
|
||||
extern void SDL_UDEV_DelCallback(SDL_UDEV_Callback cb);
|
||||
extern const SDL_UDEV_Symbols *SDL_UDEV_GetUdevSyms(void);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue