Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable touch event propagation #830

Closed
wants to merge 1 commit into from
Closed

Conversation

Plantain
Copy link

Touch events are inexplicably prevent from propagating while mouse clicks propagate fine.
Fix for #617

Requires testing across some more devices.

@raysuelzer
Copy link

Please merge this.

@sergei-zelinsky
Copy link

Are there any updates on this PR? Will it be merged or not?

Thanks!

godismyjudge95 added a commit to godismyjudge95/mapbox-gl-draw that referenced this pull request Feb 20, 2019
This is to fix mapbox#617
It allows the event to propagate through if there are no mapbox targets nearby.
This sort of breaks the one tap move drawing functionality, but still allows for the double tap to move the drawing.
It also enables popups and clusters to work again.

I believe this is the best temporary solution until another is found.  The one provided by @Plantain here:  mapbox#830
basically broke drawing completely on some browsers.  I have tested extensively and am employing the patch to all my apps.
@kkaefer kkaefer added bug events Events that are fired when the user interacts with the map touch-specific labels Jan 7, 2020
@karimnaaji karimnaaji closed this Jun 16, 2020
@karimnaaji karimnaaji reopened this Jun 17, 2020
@karimnaaji karimnaaji changed the base branch from master to main June 17, 2020 17:14
@rreusser
Copy link
Contributor

rreusser commented Feb 26, 2021

This looks closely related to #869, with the exception that that PR moves this until later instead of preventing default altogether. I think this PR can be closed in favor of that one. cc @arindam1993

@m-vo
Copy link

m-vo commented Mar 28, 2021

Is there anything preventing this PR from being merged + released?

Just for the record: This bug makes using mapbox virtually impossible with Chrome devtools opened in 'touch device mode' and I fear the same is true for all devices supporting both mouse + touch. Placing and moving a point for instance works, but no draw.update events will be fired on touch interaction. Bummer. 😢

@stepankuzmin
Copy link
Contributor

stepankuzmin commented Jan 25, 2023

Hi! I'm sorry for not getting back to you sooner. We've switched to passive event listeners instead of preventDefault here, and this should be fixed in the next release #1146

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug events Events that are fired when the user interacts with the map touch-specific
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants