title: Set mouse position in software
body: <p>I am using an Android Stick (<a href="http://www.geekbuying.com/item/Uhost-2-Dual-Core-TV-Box-Mini-PC-Android-4-0-4-RK3066-Cortex-A9-1-6GHZ-1GB-RAM-4G-ROM-with-Bluetooth-WIFI-Skype-XBMC---Black-312467.html" rel="noreferrer">http://www.geekbuying.com/item/Uhost-2-Dual-Core-TV-Box-Mini-PC-Android-4-0-4-RK3066-Cortex-A9-1-6GHZ-1GB-RAM-4G-ROM-with-Bluetooth-WIFI-Skype-XBMC---Black-312467.html</a>) for building an application. The application uses an attached USB webcam for some of it's functionality. Additionally, I connect a mouse to this device which the user can use to navigate through various pages in the application. A left/right movement of the mouse results in navigation to previous/next page.</p>
  
  <p>While the mouse works with the Android device, I additionally require to reset the position of the mouse to the center after every single interaction with the user. Is it possible to set the mouse position using software in Android? I am using <code>View.OnGenericMotionListener</code> to capture the mouse movement.</p>
  
  <p>Currently, I also require to perform a primary mouse button click to bring the mouse in focus inside the application. I want to remove this requirement by either generating the primary mouse button click in software, or otherwise bring the application in software by some other means.</p>
  
  <p>I have been unable to find any APIs to get the above to work. Any help on these would be greatly useful.</p>
  
  <p>Just in case I need to write some sort of drivers to get this thing working, any help in this direction would also be useful.</p>
  
  <p>Any workarounds around this problem, while still using the mouse, could also prove useful.</p>