Wine currently lacks XInput support, which means that one can't use gamepads in many modern games. So I did a bit of Wine hacking, temporary results are in this patch and they work with the SimpleController.exe example from the Microsoft SDK.
Some notes about the patch:
- behaviour on window focus-leave/enter is wrong (disconnects the controller, instead of just disabling events)
- it only works with xboxdrv, not with xpad (due to the different order of buttons)
- I so far only implemented the bare minimum to get SimpleController.exe to run, so some parts of the API are still missing and it might not work with a full game
- it is a quick&dirty patch, proper patch would need some magic to detect the controller dynamically
- no rumble