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

BackStack issue with <fragment> destinations #1

Open
massivemadness opened this issue Mar 19, 2022 · 0 comments
Open

BackStack issue with <fragment> destinations #1

massivemadness opened this issue Mar 19, 2022 · 0 comments
Assignees
Labels
bug Something that needs to be fixed

Comments

@massivemadness
Copy link
Owner

massivemadness commented Mar 19, 2022

Describe the bug
There's an issue when navigating from <swipeable> to <fragment> destination, the fragment will not be added to the backstack, which makes impossible to go back using popBackStack() or navigateUp() methods.

To Reproduce
Steps to reproduce the behavior:

  1. Make <swipeable> your start destination
  2. Navigate to a <fragment> destination
  3. Call popBackStack() to return to the previous fragment

Any ideas of how to fix
The issue is not exactly in SwipeBackNavigator, It's the default behavior of androidx.navigation.fragment.FragmentNavigator, which depends on the backstack size to decide whether it should add a transaction to the backstack or not.

Снимок экрана 2022-03-19 в 13 39 43

Снимок экрана 2022-03-19 в 13 41 00

@massivemadness massivemadness added the bug Something that needs to be fixed label Mar 19, 2022
@massivemadness massivemadness self-assigned this Mar 19, 2022
@massivemadness massivemadness added the help wanted Extra attention is needed label Mar 19, 2022
@massivemadness massivemadness removed the help wanted Extra attention is needed label Apr 9, 2022
@massivemadness massivemadness changed the title BackStack issue when navigating to a <fragment> destination BackStack issue with <fragment> destinations Jun 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something that needs to be fixed
Projects
None yet
Development

No branches or pull requests

1 participant