ReadYouApp / ReadYouApp/ReadYou
AlertDialog disappears on system-initiated process death 2
Nobody has claimed this yet.
- Dominant language
- Kotlin
- Stars
- 7.5k
- Forks
- 330
- PR merge metrics
- No merged PRs in 30d
Description
1. Environment
- Device: [Xiaomi Redmi Note 8 Pro]
- OS: [Android 14]
- APP: [0.9.12]
Note: not fixed in 0.10.1
2. Describe the bug
This article explains why it matters: Save UI State - Android Developers
Problem: when I perform this sequence of events the AlertDialog disappears:
- Touch the settings icon at the top left
- Touch Accounts
- Touch an account
- Touch Clear all articles
- background/foreground app with "Don't Keep Activities" option enabled
or:
- Touch the settings icon at the top left
- Touch Accounts
- Touch an account
- Touch Delete account
- background/foreground app with "Don't Keep Activities" option enabled
Possible solution:
- app/src/main/java/me/ash/reader/ui/page/settings/accounts/AccountViewModel.kt
- variable accountUiState: move state holder from ViewModel to the Composable using rememberSaveable at least for fields deleteDialogVisible and clearDialogVisible.
Screenshots:
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with app/src/main/java/me/ash/reader/ui/page/settings/accounts/AccountViewModel.kt, focusing on accountUiState and the deleteDialogVisible and clearDialogVisible fields. Reproduce the account deletion or article-clearing flow with Android's "Don't Keep Activities" option enabled, then verify that the appropriate AlertDialog remains visible after the app is backgrounded and restored.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 52/100