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

Write settings to permanent storage when OS or user force kills app #4995

Merged
merged 3 commits into from
Jan 31, 2024

Conversation

nirvn
Copy link
Member

@nirvn nirvn commented Jan 30, 2024

I was testing #4988 on iOS yesterday when I realized modified settings were for the most part never saved. That's because on iOS, there's no double back button quitting per say, only force quitting by swiping the app up.

This commit remedies to that situation. It also benefits Android when people force kill app. Simple step to reproduce issue:

  • Open QField
  • Load bees project
  • Add a navigation destination (long press on canvas -> set as destination)
  • Suspend QField, then force kill it by showing running apps and swipping QField up into nonexistence)
  • Re-open QField, destination gone.

@qfield-fairy
Copy link
Collaborator

qfield-fairy commented Jan 30, 2024

Copy link
Collaborator

@suricactus suricactus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good, good move. On the firstRunFlag, +1 on renaming. Just make sure it is properly working, it is a workaround for Linda's bug (tm). Cannot test myself.

@m-kuhn
Copy link
Member

m-kuhn commented Jan 30, 2024

it is a workaround for Linda's bug (tm)

For what I know, this bug is no more and was properly fixed (by using a newer SDK for the complete set of dependencies)

@nirvn nirvn merged commit e3942ec into master Jan 31, 2024
19 checks passed
@nirvn nirvn deleted the settings branch January 31, 2024 02:54
@suricactus
Copy link
Collaborator

I am not aware if we use this flag for something else? If not, it is safe to be removed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants