Open
Bug 1214368
Opened 10 years ago
Updated 3 years ago
Swipes and pinches should not be translated into wheel and zoom events on Windows/Surface
Categories
(Core :: DOM: Events, defect, P5)
Tracking
()
UNCONFIRMED
People
(Reporter: maxkfranz, Unassigned)
Details
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:41.0) Gecko/20100101 Firefox/41.0
Build ID: 20150929144111
Steps to reproduce:
Swipe down on a canvas element on a Windows/Surface device in desktop Firefox
If you clone Cytoscape.js (https://github.com/cytoscape/cytoscape.js) and open the debug page, you'll have a good place to test. Note that the graph zooms in as if a mousewheel were used. This makes panning very difficult.
Similarly, if you pinch, the whole page is zoomed and there is no way to prevent this on particular DOM elements.
Actual results:
`wheel` events are generated
Expected results:
`mousedown` and `mousemove` events should be generated if touch events like `touchstart` are not supported
The expected results are gotten if you swipe left or right instead of down or up.
This wheel behaviour and the zoom behaviour ought to be preventable via `event.preventDefault()`. The zoom behaviour being preventable is not so important if touch events aren't supported -- but if they are, then pinch to zoom needs to be preventable.
Ref to Cytoscape issue : https://github.com/cytoscape/cytoscape.js/issues/323
Updated•10 years ago
|
Component: Untriaged → DOM: Events
Product: Firefox → Core
Comment 3•9 years ago
|
||
Getting this problem too in several libraries including Leaflet.js, GoJS, and Mapbox. Finger-panning on the surface when you start left-or-rightwards is just fine, but starting with an up-or-down motion causes wheel events instead, breaking the functionality of these libraries.
This works in all other browsers.
On the leaflet home page if you pan left and right you get appropriate events, but panning up and down on the map results in map zoom: http://leafletjs.com
This is also true in Mapbox, example on github: https://github.com/smartchicago/chicago-atlas/blob/master/db/import/zipcodes.geojson
This is also apparent in GoJS where left-and-right finger motions appropriately make mouse events, but up-and-down motions activate the page scrollbar: http://gojs.net/beta/samples/minimal.html
This can also be seen on simplistic test cases, such as the one shown here: https://gist.github.com/anonymous/f1ad539cba5e0fa9859d
Updated•7 years ago
|
Priority: -- → P5
Updated•3 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•