Exposing GoogleMap.OnCameraMoveStartedListener "reason"
See original GitHub issueI hooked up fusedLocationClient to cameraPositionState to keep current location regularly updated. I have some logic related to the isMoving
flag. However I noticed that this flag is constantly toggling.
Could we expose OnCameraMoveStartedListener so I can check the reason as a flag instead? https://developers.google.com/android/reference/com/google/android/gms/maps/GoogleMap.OnCameraMoveStartedListener
This is currently not exposed. Thanks ❤️!
Issue Analytics
- State:
- Created a year ago
- Comments:7 (6 by maintainers)
Top Results From Across the Web
GoogleMap.OnCameraMoveStartedListener
Called when the camera starts moving after it has been idle or when the reason for camera motion has changed. Do not update...
Read more >Is there a way to listen to pans only with GoogleMaps API in ...
OnCameraMoveStartedListener () { @Override public void onCameraMoveStarted(int reason) { CameraPosition ... getCameraPosition(); if (reason == GoogleMap.
Read more >How can I handle map move end using Google Maps for ...
OnCameraMoveListener and GoogleMap.OnCameraIdleListener . If, for some reason, you want to use the older API which is now deprecated you can use ...
Read more >Prohibited and restricted content - Local Guides Help
Google Maps is a place for safe exploration of the world around us. For that reason, we don't allow sexually explicit content. This...
Read more >Places that are not on Google Maps - Quartz
Side-by-side images expose a glitch in Google's maps. Now you see it ... If your city is not on Google maps, does that...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks @arriolac, that makes sense. I can try tackling this. My plan would be to finish the work in PR https://github.com/googlemaps/android-maps-compose/pull/94 that adds more examples in the app, and then add this feature along with a sample implementation in the demo app.
Thanks for clarifying @barbeau . It looks like the library is swallowing the
reason
flag and should be exposed as a property toCameraPositionState
. See: https://github.com/googlemaps/android-maps-compose/blob/main/maps-compose/src/main/java/com/google/maps/android/compose/MapUpdater.kt#L72