Closed Bug 1006495 Opened 10 years ago Closed 10 years ago

TouchForwarding - forwards inaccurate or no touch coordinates

Categories

(Firefox OS Graveyard :: Gaia::System, defect)

All
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED DUPLICATE of bug 984897

People

(Reporter: olle.klang, Unassigned)

References

Details

Touchforwarding via iframe.sendTouchEvent is not working properly. (The sendTouchEvent is used by touch_forwarder.js which is used by the edge-swipe-detector.)  

What happens?
The coordinates of the touches that are forwarded are not accurate (issue A) and sometimes touches do not get forwarded at all (issue B).

Issue  A -  inaccurate touches 
Steps to reproduce:  
- Enable edges gestures in the developer menu in the settings app. 
- With edges gestures enabled try to touch any other row in the settings app developer menu with a checkbox and be sure to touch at the very right side of the phone (where the edge-gesture-detector div overlaps the app).    

Expected result:  
The touched rows checkbox should be checked/unchecked.    

Actual result:  
The checkbox on the row two or three lines above gets checked/unchecked.  

Issue B -  unforwarded touches 
The top part of the targeted iframe stays unresponsive of touchevents.    

When? 
The issue occurs if the receiving iframe is not positioned at the top of the screen. The lower the iframe is positioned on the screen the bigger the unresponsive part of the iframe gets, i.e. the worse the issue gets.  

Steps to reproduce:      
- Enable edges gestures in the developer menu.      
- Open the Calendar app in week or day view.      
- Change the position of the app window:          
Change the css of the div with id "window" in the system app "top: 0" to a larger number e.g. "top: 200px".          
Either use the app manager to change the css interactively or change directly in the css file: gaia/apps/system/style/system/system.css (the latter requires a rebuild of the system app).       

- Scroll up and down along the very right or left edge of the phone (where the edge-gesture-detector div overlaps the app). Try to start the scroll both in the upper part of the window and in the lower part.       

Expected result: 
The view should scroll up and down no matter where the scroll starts.

Actual result:  
When starting the scroll in the upper parts of the app window there is no action, no touches are forwarded. When starting the scroll from the lower parts of the app window, scrolling works as expected.  

Why should we care? All apps are loaded at the top of the screen anyway...
Gadgets for the lockscreen bug 980936 and homescreen bug 980935 can be placed at any position of the screen and will need this feature to be able to use left/right scrolling to change gadget and longtap to remove gadgets but still forward other touches to interact with the gadgets.

Device used has a screensize of 1280 x 720px and device pixel ratio of 1.5.
Blocks: 980935, 980936
Flags: needinfo?(21)
I think I know what's going on. Likely my fault because of  some bad maths in bug 959242.
Blocks: 959242
Flags: needinfo?(21)
Status: UNCONFIRMED → NEW
Ever confirmed: true
This does not reproduce anymore on newly builds.
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → DUPLICATE
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.