mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-19 04:46:08 +00:00
fix: three-finger tap opens the keyboard in touchpad mode (#1903)
This commit is contained in:
1 parent
d691bcf832
commit
b63feb5eaa
4 files changed
+21
-3
No files matched your search
@@ -11,6 +11,7 @@ class PointerGestures {
|
||||
fun onScroll(dx: Float, dy: Float) {}
|
||||
fun onScrollEnd() {}
|
||||
fun onZoom(steps: Int) {}
|
||||
fun onThreeFingerTap(): Boolean = false
|
||||
}
|
||||
|
||||
companion object {
|
||||
|
||||
@@ -240,7 +240,8 @@ class TouchpadGestures(
|
||||
}
|
||||
if (desktop && scrolled && event.pointerCount == 2) listener.onScrollEnd()
|
||||
if (fingers >= 3) {
|
||||
if (event.pointerCount == 2 && secondWasTap && !scrolled && event.eventTime - downAt < TouchTiming.TAP_MS * 2)
|
||||
if (event.pointerCount == 2 && secondWasTap && !scrolled && event.eventTime - downAt < TouchTiming.TAP_MS * 2 &&
|
||||
!listener.onThreeFingerTap())
|
||||
click(PointerGestures.BTN_MIDDLE)
|
||||
if (event.pointerCount == 2) secondWasTap = false
|
||||
} else if (twoFingers && secondWasTap && event.eventTime - secondDownAt < TouchTiming.TAP_MS && !scrolled) {
|
||||
|
||||
Reference in new issue
Block a user