No pointerdown or mousedown events on Android Chrome > 55.
Also I think this issue in Leaflet.Path.Drag is actually Leaflet bug: https://github.com/w8r/Leaflet.Path.Drag/issues/29
Expecting: mousedown or pointerdown events displayed on lower part of the screen.
Have: nothing.
Repo for example above here: https://github.com/alexshk/leaflet-test-android-chrome
Thanks
Hi!
We've had quite a few issues related to change with pointer events from Chrome 55 and up, so I'm not surprised to see something like this.
However, I was unable to reproduce this on my Nexus 5X with Android 7.1.2 / Chrome 58. Clicking the triangle results in (synthetic) mouse up / down / click events in the bottom of the screen. I'm not able to drag the polygon, though.
Hi
Thanks, but I was checking for pointerdown/mousedown events, sorry for bad dscription. Clicks are fine, check please if you have such events while trying to drag blue triangle (no actual dragging functionality here, just checking for event firing). Thanks
@alexshk this is what it looks like clicking the polygon on my Nexus 5X:

So, as you can see there's mousedown as well as mouseup and click. This is not what you're seeing?
@perliedman if I tap on triangle, then yes -- I see the same. But I want to drag blue triangle. Check with desktop browsers and you'll see result I need.
Alright, now I finally see the issue. Will have to look closer.
BTW, this is reproducible in Chrome devtools on desktop with device emulation enabled.
This might be a good time to revive the pointerify branch.
Disabling L.Browser.pointer for Android Chrome seems to be working: http://leaflet-polyline-events.surge.sh/index-pointer.html
Commit: https://github.com/alexshk/Leaflet/commit/2e55b7b796419832f07249b0cb651a3ca653f743
I have tested the following and can confirm that the bug is reproducible on both:
Android 4.4.2, Chrome 58
Android 6.0.1, Chrome 55
The fix by @alexshk seems to be working. Any updates on whether or when it will be fixed in Leaflet?
As asked above, when will this be fixed? The issue can still be produced on Android 6, Chrome 68, Leaflet v. 1.3. Thx.
Test page updated for latest leaflet: https://gist.githack.com/johnd0e/219609663cf734ddf6c04ecf27adedb8/raw/issue-5556.html
Ok, I've found solution.
https://github.com/Leaflet/Leaflet/blob/d843c3b88486713827d7e860b58bdba75bfbd5a2/src/map/Map.js#L1327-L1328
Here we need to add 'pointerdown pointerup ' (or 'touchstart touchend ').
But I'm not sure: should we just add these 2 events, or make whole list customizable?
According to docs, we have limited list of supported events.
touch* and pointer* events are not implemented.
As for mousedown: it should not be fired on touch-dragging, because it is just 'compatibility mouse event', see specs.
So current behavior is valid, thus I am closing this issue.
@alexshk @nikkon226 @data-ux @joakimgunst @Damorck
Feel free to request support for additional events (in separate issue), describing your use cases.
Most helpful comment
This might be a good time to revive the
pointerifybranch.