-
-
Notifications
You must be signed in to change notification settings - Fork 442
add Samsung Galaxy Tab trackpad gestures #587
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
tap, long tap, two-finger tap, two-finger scroll tested on SM-X800, with EFDT970
…wn / mouseup event
… from the trackpad
|
I did not dive deep to changes but I already can say that kt will break support for other dex devices. Replacing one constant ( |
|
okay do we need completely different way to detect gestures? or just |
|
Again, I did not dive deep to the code. But it will be the first step. |
|
I reverted the constant |
|
Ok, I need to test this on my device and request test from one other guy. |
|
Ok, it works fine on Samsung Galaxy S20 FE (SM-G780F). |
Co-authored-by: Twaik Yont <twaikyont@gmail.com>
|
Can you please investigate why it does not work with |
|
Sure, but my device behaves very strangely (inversed X/Y axis, can't use any gestures) when I turn that option on, even before the PR code. |
|
AFAIK it should be handled by |
Co-authored-by: Twaik Yont <twaikyont@gmail.com>
|
I'm just curious, why trackpad need captured pointer? I'm not sure what the expected behavior is. |
|
The "Captured Pointer" feature offers several advantages. Firstly, the navigation and status bars do not appear when the mouse touches the top or bottom edges of the screen. Secondly, Android sends relative mouse events instead of the absolute ones typical in regular mode. This is particularly important in scenarios like 3D games or 3D editors, or in any other situation where an X11 application manipulates the cursor's position, and this behavior needs to be taken into account. |
|
in my device, just removing below code fixes the issue. TouchInputHandler.java: // Regular touchpads and Dex touchpad send events as finger too,
// but they should be handled as touchscreens with trackpad mode.
if (mTouchpadHandler != null && (event.getSource() & InputDevice.SOURCE_TOUCHPAD) == InputDevice.SOURCE_TOUCHPAD) {
return mTouchpadHandler.handleTouchEvent(view, view, event);
}With trackpad mode, all gestures including tap, long tap to drag, two-finger tap, two-finger scroll, even three-finger tap are handled well. but X/Y axis are still ininverted. It looks like Android or my trackpad is reporting the wrong MotionEvent. As you said we might need an option to invert this. |
|
|
press the left button with one finger and move to drag with the other
|
There is no |
|
Or it is only for the case of Dex? Yeah, it seems like yes. |
|
My device supports two-finger dragging. I can use this gesture in any android app, not just termux-x11. |
|
I am not really sure about this. Need some check. |
yes! Is there anything else I need to do before it merges? |
|
Currenly I have to do some checks on real device. |
|
Probably that is safe, but I can not reproduce two-finger drag behaviour. |
add some gestures of Samsung Galaxy Tab trackpad (SEC-EFDT970).
tested on Samsung Galaxy Tab S8+ (SM-X800), Android 14, OneUI 6.0
I also recorded
MotionEvents when I gesture: