You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Camera manipulation not working within onLongPress #2738
One solution is to always return true if there is a longPress javascript handler, another one is to interrupt the gesture handler once the javascript code was run.
Having the same issue. Works when using onPress but onLongPress does not allow me to setCamera. I tried returning true from all my handlers but did not resolve.
Activity
mfazekas commentedon Mar 28, 2023
@michalpazur thanks much for the report the issue is that we report false from longClick handler.
maps/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/mapview/RCTMGLMapView.kt
Lines 647 to 653 in 97459e2
https://docs.mapbox.com/android/maps/api/10.12.1/mapbox-maps-android/com.mapbox.maps.plugin.gestures/-on-map-long-click-listener/on-map-long-click.html
One solution is to always return true if there is a longPress javascript handler, another one is to interrupt the gesture handler once the javascript code was run.
cometman commentedon Nov 24, 2023
Having the same issue. Works when using
onPressbutonLongPressdoes not allow me tosetCamera. I tried returning true from all my handlers but did not resolve.