Hi,
I've download Jim's source code for the WM_inputExample and its working great, I can send keypress data using sendinput() MFC stuff. However, I can't seem to get the example to respond when its window is not in focus, it only works when its forefront. This is the same when I choose to call a messagebox when the input changes (from the stick).
Is there any way to have the program respond permanently in the background, polling for new data and sending the keypress data to whichever window is currently in focus?
mimic keypress
Moderator: Moderators
Re: mimic keypress
Hi rhumba,
I believe you need to set the RIDEV_INPUTSINK flag.
Note that we do not recommend that you do this. If your application is on system running other apps that also support 3D mice, then unwanted/unexpected manipulation of your app can occur when it is on the background.
Please refer to the MSDN documentation on the RAWINPUTDEVICE structure has used in ::RegisterRawInputDevices () function.Is there any way to have the program respond permanently in the background, polling for new data and sending the keypress data to whichever window is currently in focus?
I believe you need to set the RIDEV_INPUTSINK flag.
Note that we do not recommend that you do this. If your application is on system running other apps that also support 3D mice, then unwanted/unexpected manipulation of your app can occur when it is on the background.
Nuno Gomes