Don't dispatch touchmove events if the user's finger hasn't moved far

RESOLVED FIXED in Firefox 11

Status

()

Firefox for Android
General
RESOLVED FIXED
5 years ago
3 years ago

People

(Reporter: wesj, Assigned: wesj)

Tracking

unspecified
Firefox 12
Points:
---

Firefox Tracking Flags

(firefox11 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

5 years ago
Created attachment 589652 [details] [diff] [review]
Patch

Follow up to Bug 603008. Google Maps expects that we don't dispatch touchmove events if the users finger hasn't moved much, and uses this to detect taps (and double taps). This brings us in line with their expectations.
(Assignee)

Updated

5 years ago
Attachment #589652 - Attachment is patch: true
Attachment #589652 - Flags: review?(mark.finkle)
Comment on attachment 589652 [details] [diff] [review]
Patch

>+        if (initialTouchLocation != null && (action & MotionEvent.ACTION_MASK) == MotionEvent.ACTION_MOVE) {
>+            if (PointUtils.subtract(point, initialTouchLocation).length() > PanZoomController.PAN_THRESHOLD * 240) {
>+                initialTouchLocation = null;
>+            } else {
>+                return !allowDefaultActions;
>+            }
>+        }

Is this location for setting initialTouchLocation = null good enough? I worry that something could happen and we are stuck in a non-null situation. It looks like it should be good enough, I just wanted you to think about it a bit more.
Attachment #589652 - Flags: review?(mark.finkle) → review+
(Assignee)

Comment 2

5 years ago
https://hg.mozilla.org/integration/mozilla-inbound/rev/1b16c4bd7aa2
Whiteboard: [inbound]
https://hg.mozilla.org/mozilla-central/rev/1b16c4bd7aa2
Assignee: nobody → wjohnston
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Whiteboard: [inbound]
Target Milestone: --- → Firefox 12
tracking-fennec: --- → ?
Wes, please request aurora approval
(Assignee)

Comment 5

5 years ago
Comment on attachment 589652 [details] [diff] [review]
Patch

User impact if declined: No multitouch
Testing completed (on m-c, etc.): On mc since 1/24
Risk to taking this patch (and alternatives if risky): Low risk. Mobile only. Currently disabled
Attachment #589652 - Flags: approval-mozilla-aurora?

Updated

5 years ago
Attachment #589652 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
(Assignee)

Comment 6

5 years ago
https://hg.mozilla.org/releases/mozilla-beta/rev/105917581955
status-firefox11: --- → fixed
tracking-fennec: ? → ---
You need to log in before you can comment on or make changes to this bug.