Closed BruceMok closed 3 years ago
The desktop input process might be a bit sensitive to how you send it events. You can try emulating how an actual hardware mouse might send events:
eg:
vmulti_update_mouse(vmulti, 0, 18500, 18000, 0); // move to location
Sleep(10);
vmulti_update_mouse(vmulti, MOUSE_BUTTON_1, 18500, 18000, 0); // press mouse button
Sleep(10);
vmulti_update_mouse(vmulti, 0, 18500, 18000, 0); // unpress mouse button
It works! thanks very much.
The "testvmulti.c" show us how to move mouse, but i have no idea to send mouse button event.
case REPORTID_MOUSE: // // Send the mouse report // printf("Sending mouse report\n"); //vmulti_update_mouse(vmulti, 0, 1000, 10000, 0); vmulti_update_mouse(vmulti, MOUSE_BUTTON_1, 18500, 18000, 0); break;
I'm trying to do like this, but not worked.