Patch for dinput keyboard
ovehk at ping.uio.no
Sun May 19 09:22:35 CDT 2002
On Sun, 19 May 2002, Arjen Nienhuis wrote:
> >Right. dinput.h defines it as:
> >#define DI_OK S_OK
> >so it's the canonical return value from DirectInput methods.
> DI_NOTOK whould be better.
Oh, is that what you meant. Yeah, I suppose it should have returned
something like that, but the original code didn't, and I wasn't trying to
overhaul the code beyond what was necessary to get the job done.
> It is not possible to use memcopy when dodsize != sizeof(DeviceObjectData).
Hmm. Right. The < sanity check for dodsize should probably have been a !=
check. Not sure where it came from.
> >It works in WineX since map mode 3 is actually implemented there. I may be
> >able to submit the patch that implements it if you want, it's not a very
> >big patch.
> Is map mode mode 3 not dependant on the NumLock state then? DInput
> isn't. But on the other hand, it only mathers when someone acquires the
> device while a key is pressed.
The problem I wanted to solve with map mode 3 was distinguishing left and
right shift keys. I'm not sure about numlock.
> Well here is my new patch. I only used the Hook idea and the critical
> sections. It is better now, and shorter.
OK, maybe the WineX code will be replaced with your code eventually, then.
More information about the wine-devel