-
Notifications
You must be signed in to change notification settings - Fork 153
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
Maps: Markers occasionally flicker when updating content while using zIndex #668
Comments
There are a few problems with this example. In particular Not saying the problem does not exist. Just hard to say if it does based on the example. Also, use |
Actually, for the purpose of troubleshooting you could pass the MutableState into the Map() Composable; there is a small issue in Compose with using |
Thanks for the comment @bubenheimer. I've removed the Issue can still be reproduced: Screen_recording_20250107_160116.mp4Can you expand on how you would use |
As bad as my Compose state-handling might be, commenting the |
I'd just pass the MutableState into the Map() composable instead to work around a Compose bug with rememberUpdatedState() in this case. It's just that you recompose almost everything every time I doubt it should be |
I guess what I suggested about |
It's a derivedStateOf for index == selectedLocationIndex, but that only works if selectedLocationIndex accesses a State |
I should stop commenting and leave it to the project maintainers. Your |
This issue still persist, it appeared only when using new renderer |
Environment details
Reproduced on multiple API levels on physical devices.
Steps to reproduce
When using custom markers with zIndex, updating them based on a state makes them flicker at the wrong position (lat/long) occasionally. If not using the
zIndex
paramater the problems disappears.Code example
Demo of the issue:
https://github.com/user-attachments/assets/444b7ffb-1d3b-45ff-a6b3-d90b16daa1ed
In this demo project the flickers only happens 2 or 3 times, but in our actual project, the flickering is very frequent.
Demo of the same code without
zIndex
(no issue)https://github.com/user-attachments/assets/589e6a31-c13a-4b1f-8f8b-5579a7e54574
The text was updated successfully, but these errors were encountered: