I'm implementing a custom "long press drag" composable over a GoogleMap composable ( or trying to ). To wit, I've got a structure like the following:
Box
GoogleMap
- fillMaxSize()
Canvas
- fillMaxSize()
- pointerInput(Unit) {
detectDragGesturesAfterLongPress( ... )
My drag works great. Unfortunately, it eats not only the long press drag, but all other events as well and nothing makes it through the map when my Canvas is active. I've read through the helpful
https://developer.android.com/jetpack/compose/touch-input/pointer-input/understand-gestures, but I'm not finding the solution to this problem in there.
My theory is that either
a) there's something I could do with my setup to make the gesture detector more cooperative or
b) I need to basically inline the gesture detector so that I can manage event consumption more selectively or
c) I can't use pointerInput at all and should be using something lower level?