-
Notifications
You must be signed in to change notification settings - Fork 56
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
Add Exit Dialog #3487
Add Exit Dialog #3487
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3487 +/- ##
=========================================
- Coverage 27.2% 27.2% -0.1%
Complexity 756 756
=========================================
Files 278 278
Lines 14219 14234 +15
Branches 2581 2582 +1
=========================================
+ Hits 3880 3881 +1
- Misses 9801 9815 +14
Partials 538 538
Flags with carried forward coverage won't be shown. Click here to find out more.
|
android/quest/src/main/java/org/smartregister/fhircore/quest/ui/main/AppMainActivity.kt
Outdated
Show resolved
Hide resolved
# Conflicts: # android/quest/src/main/res/values/strings.xml
android/quest/src/main/java/org/smartregister/fhircore/quest/ui/main/AppMainActivity.kt
Outdated
Show resolved
Hide resolved
if ( | ||
navController.currentDestination?.id?.equals(R.id.geoWidgetLauncherFragment)!! || | ||
navController.currentDestination?.id?.equals(R.id.registerFragment)!! | ||
) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand this implementation is based on the assumption that the entry point to the app can either be the map or register. However, a user can redirect to a register screen from the profile using the onSubmitQuestionnaire actions. Would it be possible to check if there is no more entry in the navController back stack instead to prompt this dialog?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Condition updated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, see my comment.
IMPORTANT: Where possible all PRs must be linked to a Github issue
Fixes #3479
Engineer Checklist
strings.xml
file./gradlew spotlessApply
and./gradlew spotlessCheck
to check my code follows the project's style guideCode Reviewer Checklist
strings.xml
file