Skip to content
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

Google Maps Wont restoreState properly when using restoreState = true while navigating. #663

Open
Del-S opened this issue Dec 10, 2024 · 0 comments
Labels
triage me I really want to be triaged. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Comments

@Del-S
Copy link

Del-S commented Dec 10, 2024

Environment details

  1. Library: com.google.maps.android:maps-compose:6.2.0
  2. Navigation library: androidx.navigation:navigation-compose:2.7.7

Steps to reproduce

  1. Clone this repo.
  2. Add google api key to manifest file.
  3. Navigate to Map screen and then try to navigate to Map screen again.

Observation

Lifecycle observer goes to ON_DESTROY and never makes it's way to ON_RESUME, which keeps the map in "destroyed" state and it is not usable (cannot scroll, zoom or anything else).

While not using restoreState or saveState set to true the map works fine. Also when downgrading compose map library to 6.0.0 it works properly.

It might be related to already resolved issue: #112. But due to refactor in #436 it probably happens again. Not really connected to animations this time. It is probably connected to the restoreState.

Sample video of the issue.

@Del-S Del-S added triage me I really want to be triaged. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns. labels Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage me I really want to be triaged. type: bug Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Projects
None yet
Development

No branches or pull requests

1 participant