We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4568

Summary: Provide a way to stop treating hardware mouse as a finger with SDL_TOUCH_MOUSEID events on android, and to instead receive proper hardware mouse events
Product: SDL Reporter: Ellie <etc0de>
Component: eventsAssignee: Sam Lantinga <slouken>
Status: RESOLVED INVALID QA Contact: Sam Lantinga <slouken>
Severity: normal    
Priority: P2    
Version: 2.0.9   
Hardware: ARM   
OS: Android (All)   

Description Ellie 2019-03-28 10:54:21 UTC
The hardware mouse on Android won't generate any mouse motion events unless mouse button is pressed down. Since they otherwise work fine, it would be really cool if there was a way to make it work, such that cross-platform apps that know how to do mouse hover effects can also do them on Android!

(Also this would be kind of vital for any sort of FPS wanting to do proper hardware mouse support on Android, woulnd't it?)

I tested this on Android 7.1.1
Comment 1 Ellie 2019-03-28 11:04:26 UTC
Oh right, it seems it doesn't actually generate PROPER mouse events, but only the fake SDL_TOUCH_MOUSEID events. This is really a problem for SDL2 Android apps that understand what a proper mouse is and want to support e.g. mouse aim and such things.

Can this "finger emulation" be turned off such that apps who have a proper concept of a hardware mouse can proper, non-emulated hardware mouse events with proper motion-when-not-pressed, button right-click, mouse wheel, and all of that?
Comment 2 Ellie 2019-03-28 11:09:00 UTC
*** Bug 4567 has been marked as a duplicate of this bug. ***
Comment 3 Ellie 2019-03-28 11:22:21 UTC
Oops, my google-fu just failed me and apparently this exists: SDL_HINT_ANDROID_SEPARATE_MOUSE_AND_TOUCH

sorry for the invalid ticket!