This repository has been archived by the owner on Jan 10, 2024. It is now read-only.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue
This fixes the following issue(s):
Description of the fix
The error source of #1589 is the difference between the System locale and the Application locale. Somehow the Campus-App fails to correctly set its own Application locale. This leads to the crash as the NavigatioDrawer causing it, tries to find the clicked NavItem with a localized String resource. For example see this part of code from the NavigationDrawer
menuItem.title == activity.getString(HOME.titleRes)
here menuItem.title is based in the Application locale where under certain cirqumstances activity.getString() uses the System locale. It uses the System locale after any of the NavItem.ActivityDestination has been opened.Why this is useful for all students
While it does not solve the underlying problem it still prevents the App from crashing and thus is at least a bit.
Further todos
The main problem causing this other problems and #1585 as well as maybe others is not solved with this. In regards to this I have openend the issue #1593 See there for further details.