Box {
MapView(
arcGISMap = arcGISMap, modifier = Modifier
.fillMaxSize(), graphicsOverlays = graphicOverlays, mapViewProxy = mapViewProxy
)
Box(
Modifier
.fillMaxSize()
.pointerInput(Unit) {
detectHorizontalDragGestures { change, dragAmount ->
if (isDragConsumed()) {
change.consume()
Log.d(TAG, "do drag here ")
}
}
})
}
Here a little sample of what I'm trying to achieve. I put a dummy invisible to catch the drag event and do something. I'm not sure why, but it seem to break the pan event when isDragConsumed is not trigger.
Hello,
In the code provided, you're putting two composables ( MapView and inner Box) inside a Box which causes both elements to be stacked on top of each other. This is why inner Box is consuming the events and it breaks the map panning.
Are you specifically looking to intercept horizontal gestures?
We provide a lambda on MapView that might work.
onPan: ((PanChangeEvent) -> Unit)? = null